Generate HTML preview for DAG-CBOR
Filling this for completeness, and also as bare minimum to support https://dasl.ing/, but with lower priority than other things like #342
If request for DAG-CBOR CID is made with Accept header that includes text/html, we should generate HTML preview that
- informs user that CID is DAG-CBOR
- have option to download CBOR as a raw block (
?format=raw, requires #356) - preview of CBOR document with clickable links to other CIDs (CBOR Tag 42)
Prior art in boxo/gateway: https://ipfs.io/ipfs/bafyreicnokmhmrnlp2wjhyk2haep4tqxiptwfrp2rrs7rzq7uk766chqvq/
Note:
- MVP does not have to be styled with CSS or have links to anything other than Raw Block
- we do not have conformance for this, but we should add one, that confirms CBOR Tag 42 link is present and clickable
FYI that this is in verified-fetch now and we just need to add the new plugin to our verifiedFetch options
re-opening until i confirm it's fixed on inbrowser.dev
it's available on inbrowser.dev but there is a related issue: https://github.com/ipfs/helia-verified-fetch/issues/257
leaving this open here as well to track