and react-dom as peerDependencies but they're still being installed and used from the library's node_modules folder instead of the app's (which is using the package) node_modules folder.
Anyone knows why?
Did you define it other place beside peer dependencies? Like, it is defined in dependencies?
It's defined in devDependencies
Hmm.. That looks correct.
I need it in devDependencies because of Jest.
Perhaps some other dependencies list react and react-dom as their dependencies?
Then their dependencies will be downloaded in their own node_modules folder.
Iirc the structure is flat.. What are you seeing now? You are suppose to see this app/ node_modules/ your_lib/ react/ react_dom/
Обсуждают сегодня