Yes
Yes
1.3.2
failed to compile for yarn linked packages
cannot resolve local packages
module not found when importing npm linked pacakges
yarn --version
1.3.2
node -v
v8.9.1
npm -v
5.5.1
yarn --version
1.3.2
npm ls react-scripts
└── [email protected]
Then, specify:
(Write your steps here:)
It should resolve the module.
I see the module is symlinked within node_modules, but the app is looking only relative to the component:
Failed to Compile
Module not found: Can't resolve 'react-checkbox-tree' in '/Users/un/gd/client/src/modules/categories/components'
It is failing because the main entry of react-checkbox-tree points to lib/index.js. But that file doesn't exist if you just clone a repository.
If you run yarn build in react-checkbox-tree, that will create the lib folder. If you manage to get it building (I had to remove linters from the gulpfile because they failed for me), linking will work.
@gaearon Got it, thanks!!!
@gaearon when I'm running yarn build in the package's folder, yarn returns error Command "build" not found.
Oh ... thank you @bugzpodder
Most helpful comment
It is failing because the main entry of
react-checkbox-treepoints tolib/index.js. But that file doesn't exist if you just clone a repository.If you run
yarn buildinreact-checkbox-tree, that will create thelibfolder. If you manage to get it building (I had to remove linters from the gulpfile because they failed for me), linking will work.