You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Aug 9, 2022. It is now read-only.
Swarm has support for specifying content-type. Currently, it is possible to define content-type with .get(<<buffer>>, { contentType: 'plain/text' }) but only for raw files. When the data are given filename then it won't work the same as for Directories.
The support is hanging on implementing content-type support for directories which are uploaded as Tar files. According to input from Swarm team it is possible using xattr: user.swarm.content-type. It would be best to have this directly integrated using Erebos which will need some work on that part: MainframeOS/erebos#133
Old issue
Swarm has very tight coupling between files and their content-types.
IPFS, on the other hand, does not have any support for specifying the content type of files. It uses go mime sniffer for determinating it when serving files over gateway. There is accepted proposal ipfs/kubo#6214 that will enable this in the future, yet it is question when it will happen.
What should be our way? I see to options:
support content-types, but ignore it for IPFS
ignore content-types, and use raw mode for Swarm
The text was updated successfully, but these errors were encountered:
Swarm has support for specifying content-type. Currently, it is possible to define content-type with
.get(<<buffer>>, { contentType: 'plain/text' })
but only for raw files. When the data are given filename then it won't work the same as for Directories.The support is hanging on implementing content-type support for directories which are uploaded as Tar files. According to input from Swarm team it is possible using
xattr: user.swarm.content-type
. It would be best to have this directly integrated using Erebos which will need some work on that part: MainframeOS/erebos#133Old issue
Swarm has very tight coupling between files and their content-types.
IPFS, on the other hand, does not have any support for specifying the content type of files. It uses
go
mime sniffer for determinating it when serving files over gateway. There is accepted proposal ipfs/kubo#6214 that will enable this in the future, yet it is question when it will happen.What should be our way? I see to options:
raw
mode for SwarmThe text was updated successfully, but these errors were encountered: