-
Notifications
You must be signed in to change notification settings - Fork 30
Apps and remainder paths #73
Comments
cc @mildred @davidar @cleichner @wking -- you may be interested in this |
This seems quite complex for me. Why not, but I like the simplicity of one path = one object that could be fetched directly without needing the intelligence of a specific application. Typically, single page applications use the hash part of the URL to route to part of themselves, and I'm comfortable with that. What's the advantage of I'm not against it, I would just like to be convinced better. |
Just a small note, don't wanna derail -- there are options laid out for |
@mildred it's not without precedent:
|
See dylanPowers/ipfs-chrome-extension#10 (comment)
Suppose we have an IPFS Path / URI like:
And suppose that:
/dns/ipfs.pics/view
is an application -- say a webapp that views images/ipfs/QmagBFqo41RrHpk3GKvBCpjrd2H61ntgaQWNMVasZuJJn3
is an imageNaturally, the ipfs object representing
/dns/ipfs.pics/view
would not have the entirey of the/ipfs
pathspace underneath it, but perhaps it could signal the capacity to process remainders of paths. If so, then browsers with ipfs support could run the application at/dns/ipfs.pics/view
and feed/ipfs/QmagBFqo41RrHpk3GKvBCpjrd2H61ntgaQWNMVasZuJJn3
as a parameter.The goal is to achieve something similar to how web application servers and single-page webapps do URL path routing today, or how unix filesystems can mount other filesystems at specific mount points. In both cases, the remainder of paths get forwarded on to applications underneath.
One possible way to achieve this is to define a special key/value in an ipfs object that sets it as a valid return value for ALL subpaths, for example, suppose the object at
/dns/ipfs.pics/view
included:then, when an ipfs-implementation-powered browser viewed
/dns/ipfs.pics/view/ipfs/QmagBFqo41RrHpk3GKvBCpjrd2H61ntgaQWNMVasZuJJn3
it would:/dns/ipfs.pics/view
ipfs
link underneath it@mount: true
/dns/ipfs.pics/view
as a webapp/ipfs/QmagBFqo41RrHpk3GKvBCpjrd2H61ntgaQWNMVasZuJJn3
Note:
window.location.pathname
and prune out the prefix, using the rest as the argument.The text was updated successfully, but these errors were encountered: