Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

IPNS prefetching #643

Open
magik6k opened this issue Dec 18, 2018 · 2 comments
Open

IPNS prefetching #643

magik6k opened this issue Dec 18, 2018 · 2 comments
Labels
status/blocked/missing-api Blocked by missing API status/blocked/upstream-bug Blocked by upstream bugs status/blocked Unable to be worked further until needs are met status/deferred Conscious decision to pause or backlog

Comments

@magik6k
Copy link
Member

magik6k commented Dec 18, 2018

I don't know how tricky this may be, but go-ipfs 0.4.18 has --stream flag for ipfs 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 normal ipfs 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 call ipfs 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)

@lidel
Copy link
Member

lidel commented Dec 21, 2018

Thank you, I agree this could improve UX of IPNS websites.

I imagine we would do this:

  • IF URL is for /ipns/.. and webRequest.ResourceType=main_frame (top-level document loaded into a tab)
    • THEN redirect to the special "IPNS loading page" that
      • does ipfs name resolve --stream and displays discovery progress
      • enables user to decide "current result is good enough" and navigate to that page

@lidel lidel added UX status/blocked/missing-api Blocked by missing API status/blocked/upstream-bug Blocked by upstream bugs status/deferred Conscious decision to pause or backlog labels Dec 21, 2018
@da2x
Copy link

da2x commented Dec 24, 2018

This could also be useful for framed content; like an iframe with a video or something.

@jessicaschilling jessicaschilling added status/blocked Unable to be worked further until needs are met and removed UX labels Mar 30, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status/blocked/missing-api Blocked by missing API status/blocked/upstream-bug Blocked by upstream bugs status/blocked Unable to be worked further until needs are met status/deferred Conscious decision to pause or backlog
Projects
No open projects
Status: Needs Grooming
Development

No branches or pull requests

4 participants