Skip to content

Better handling of file extensions in the browser #574

@agmap

Description

@agmap

Many files are not wrapped in a directory. The file extension is therefore missing.
But browsers seem to extract the file extension from the magic numbers / file signatures.

Json files
When I open a json file in ipfs.io, it gets the correct file extension.
When I open a json file in inbrowser.link its in an HTML page. I can’t download it as json.
For example:
https://ipfs.io/ipfs/bafkreieze572daxva52asutm4u2bgtjtifur2a4d2aiur7lymjcwhoeqyy
https://bafkreieze572daxva52asutm4u2bgtjtifur2a4d2aiur7lymjcwhoeqyy.ipfs.inbrowser.link/

The same applies to image files:
If I open an image in ipfs.io, the image gets the correct file extension
If I open an image file in inbrowser.link, it is in an HTML page and I cannot download it as an image from the browser.
Example:
https://ipfs.io/ipfs/bafybeiblgxritjybxffn5te6aupebq7m77xm7xiqqkiq7eete7wrblhnce
https://bafybeiblgxritjybxffn5te6aupebq7m77xm7xiqqkiq7eete7wrblhnce.ipfs.inbrowser.link/

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingstatus/blockedUnable to be worked further until needs are mettopic/interopInteroperability

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions