gatsby-plugin-ipfs
gatsby-plugin-ipfs copied to clipboard
Support for Gatsby v4
Hey - thanks for creating this plugin!
I just created a new (v4) Gatsby site. When I try to install this plugin I receive this error:
~/code/ef/gatsby-ipfs on master via ⬢ v14.17.6
➜ npm i --save gatsby-plugin-ipfs
npm ERR! code ERESOLVE
npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR!
npm ERR! While resolving: [email protected]
npm ERR! Found: [email protected]
npm ERR! node_modules/gatsby
npm ERR! gatsby@"^4.0.0" from the root project
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer gatsby@"^2.0.0" from [email protected]
npm ERR! node_modules/gatsby-plugin-ipfs
npm ERR! gatsby-plugin-ipfs@"*" from the root project
npm ERR!
npm ERR! Fix the upstream dependency conflict, or retry
npm ERR! this command with --force, or --legacy-peer-deps
npm ERR! to accept an incorrect (and potentially broken) dependency resolution.
Seems we'll need to upgrade this plugin to work with v4?
If it does work correctly for gatsby 4 out of the box, yes we can just update the peer dependency.
Does it work correctly so far?
I can get it to run, but after the build, pages have this error:
Uncaught SyntaxError: missing ) after argument list
the error is in the gatsby core file loader.js. Not sure why yet, maybe something different with how v4 renders and caches pages?
@chrisschaub did you find a solution to this? it's exactly where i'm at.
I did not. I think it's the plugin lagging behind Gatsby versions. I'll try to have a look in a bit.
any update on this guys ? .. since I have npm <7 I get warnings that ipfs plugin(i have ver 2.0.2) is not cool with gatsby 4.11.1..
soooo.. site comes up BUT.. some links seem to not work.. especially file downloads
is the workaround to back off the gatsby version back to 2. ? or did the ipfs plugin get upgraded so its cool with 4.11.1 ?
thanks in advance
UPDATE.. trying new ipfs dependency as on gatsby site.. gatsby-plugin-runtime-path-prefix. for ipfs/ swarm. v 2.0.1
Hey - thanks for creating this plugin!
I just created a new (v4) Gatsby site. When I try to install this plugin I receive this error:
~/code/ef/gatsby-ipfs on master via ⬢ v14.17.6 ➜ npm i --save gatsby-plugin-ipfs npm ERR! code ERESOLVE npm ERR! ERESOLVE unable to resolve dependency tree npm ERR! npm ERR! While resolving: [email protected] npm ERR! Found: [email protected] npm ERR! node_modules/gatsby npm ERR! gatsby@"^4.0.0" from the root project npm ERR! npm ERR! Could not resolve dependency: npm ERR! peer gatsby@"^2.0.0" from [email protected] npm ERR! node_modules/gatsby-plugin-ipfs npm ERR! gatsby-plugin-ipfs@"*" from the root project npm ERR! npm ERR! Fix the upstream dependency conflict, or retry npm ERR! this command with --force, or --legacy-peer-deps npm ERR! to accept an incorrect (and potentially broken) dependency resolution.
Seems we'll need to upgrade this plugin to work with v4?
you were running npm 7+ ? see I just got warnings because I am running npm < v7. .. BUT.. I still get a site that doesnt have all file download links working.. site comes up ok and compiles ok with warnings.. but misbehaves
@satazor I created a PR that fixes the issue here https://github.com/moxystudio/gatsby-plugin-ipfs/pull/26
everything boots fine for me, no errors, link works fine using brave ipfs browser, but i cant get it to work on any public gateway. Link either removes the hash from the endpoint, or the page never loads. Even with @Odin94 pr. you guys have same issue?