react-boilerplate: npm run setup fails
npm run setup fails after cloning the repo
OS: Ubuntu 14.04 node: 4.4.7 npm: 2.15.8
The following error is thrown
Cannot find module 'lodash/defaultsDeep'
About this issue
- Original URL
- State: closed
- Created 8 years ago
- Comments: 23 (13 by maintainers)
Hereβs my solution overall: With the fear of having a mess with my npm and node versions (cuz Iβm using nvm and i didnβt want to get some version conflicts), what I did at the end was
Everything just started working π @tomers @VladislavSournine
Installation failed for me on node v5.12.0 (npm v3.8.6). (before I opened package.json I had two tries with 4.6) No problems with latest version (6.9.1 - with and without Yarn). Since I didnβt use Yarn before (I wish I new about it during my last project!) it took be around 30mins to check all scenarios.
Information about supported node version in quick start section of readme would definitely improve first impression (also would prevent people forced to use certain version of node from trying and raising issues). After all it is a quick start π
P.S. great work, thanks!
I happened to have npm<3 and I just checked out latest revision (Ubuntu 16.04 x64). I did not get a proper error message ([ERROR: React Boilerplate] You need npm version @>=3), as suggested by https://github.com/mxstbr/react-boilerplate/blob/3816242347c732b81686961d4faf6f7776ae309a/internals/scripts/npmcheckversion.js#L6. Instead, I got the following cryptic error message:
Yes,
package.jsonshould mention node as well.But IMHO, the code should serve as documentation as much as possible, because DRY. A middle ground could be to reference that package.json section from the README (so that the version is only written once and therefore doc wonβt become incoherent later on when package.json changes).