Closed nimahkh closed 3 years ago
I just read your comment in the article that you wrote. https://blog.harveydelaney.com/creating-your-own-react-component-library/
When the component library is symlinked, the devDependencies are persisted (react + react-dom). This will cause the duplicate React issue linked above.
I recommend doing this:
Assuming myapp and mylib are sibling folders, one possible fix is to run npm link ../myapp/node_modules/react from mylib. This should make the library use the application’s React copy.
So I published it on npm and install it from npm, it fixed now, great
Hello guys, and thanks to @HarveyD for this great repository . I have a problem when I use the code below:
it gives me this error on test project :
And it is how I used it on my Test:
What is wrong with it?