Open magik6k opened 5 years ago
Thank you, I agree this could improve UX of IPNS websites.
I imagine we would do this:
/ipns/..
and webRequest.ResourceType
=main_frame
(top-level document loaded into a tab)
ipfs name resolve --stream
and displays discovery progress
--stream
in https://github.com/ipfs/js-ipfs-http-client/issues/916This could also be useful for framed content; like an iframe with a video or something.
I don't know how tricky this may be, but go-ipfs 0.4.18 has
--stream
flag foripfs name resolve
which makes it return names as they are discovered. It has some nice properties - names returned later are guaranteed to be 'better' (newer), last name returned before the stream is closed is always what would be returned by normalipfs name resolve
. This makes initial name discovery much, much faster, usually less than 1s from my testing.When user goes to
/ipns/Qm..
path, companion could try to callipfs name resolve --stream
instead going directly to the gateway and prefetching/start displaying stuff in something like a sandboxed iframe (if something like this exists)