waku: dev: error when using locally linked version of waku
I’m trying to link a local version of Waku into our own project code to quickly iterate on PR’s and test them in a real use case, but I keep getting the follow error:
TypeError: Cannot read properties of null (reading 'use')
at react_production_min.use ([...]/waku-test/dist/ssr/assets/rsc0-b97afaf68.js:324:22)
at Slot ([...]/waku-test/dist/ssr/assets/rsc0-b97afaf68.js:10168:40)
Can be reproduced by:
git clone git@github.com:dai-shi/waku.git
cd waku
pnpm install
pnpm compile
cd ..
pnpm create waku # choose name 'waku-test'
cd waku-test
pnpm remove waku
pnpm add ../waku/packages/waku
pnpm build
Did anybody encounter this or have an idea what could cause it?
About this issue
- Original URL
- State: closed
- Created 3 years ago
- Comments: 19 (18 by maintainers)
Yes, I can confirm it works!
And I learned about the
dedupeoption, which solved two other duplicated-package issues we had as well 😱 Thank you very much!It’s a different issue from this one. Let’s continue discussions in #1037.
That’s what I thought too but it’s different from what
dedupesolves.I think this issue can be closed. Only remaining thing is either add the technique in ./docs or always use
dedupein the waku core.@rmarscher sounds good, thanks for trying that out!
This is true, but if I’m not mistaken, overrides are done differently depending on repo setup (monorepo or not) and also based off which package manager is used. IMO we should avoid opinions on package managers and attempt to fix this with vite if we can (which seems to work well so far)
I’ve been following this recharts issue about
react-is… it’s useful info here, but worth nothing that recharts as a library cannot have opinions on how to use the bundler. We can have opinions on this and do that by managing the vite config, sodedupefeels like the right mechanism for us here.Let’s see if @pmelab can solve his problem with https://github.com/dai-shi/waku/issues/676#issuecomment-2519495434 solution first.
Just double checked and yes it is