Cannot find module 'babel-loader' after eject
See original GitHub issueIs this a bug report?
Yes
Environment
OS: Mac os X 10.13.4
Node: v10.1.0/v9.11.1
yarn: v1.6.0
create-react-app: v1.5.2
react-scripts: v1.1.4
Description:
After running create-react-app my-app
, yarn start
works just fine. However after running yarn run eject
and type yarn start
again, the issue pumps out below:
yarn run v1.6.0
$ node scripts/start.js
internal/modules/cjs/loader.js:550
throw err;
^
Error: Cannot find module 'babel-loader'
at Function.Module._resolveFilename (internal/modules/cjs/loader.js:548:15)
at Function.resolve (internal/modules/cjs/helpers.js:18:19)
at Object.<anonymous> (/Users/norn/Desktop/my-app-9/config/webpack.config.dev.js:145:29)
at Module._compile (internal/modules/cjs/loader.js:654:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:665:10)
at Module.load (internal/modules/cjs/loader.js:566:32)
at tryModuleLoad (internal/modules/cjs/loader.js:506:12)
at Function.Module._load (internal/modules/cjs/loader.js:498:3)
at Module.require (internal/modules/cjs/loader.js:598:17)
at require (internal/modules/cjs/helpers.js:11:18)
at Object.<anonymous> (/Users/norn/Desktop/my-app-9/scripts/start.js:31:16)
at Module._compile (internal/modules/cjs/loader.js:654:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:665:10)
at Module.load (internal/modules/cjs/loader.js:566:32)
at tryModuleLoad (internal/modules/cjs/loader.js:506:12)
at Function.Module._load (internal/modules/cjs/loader.js:498:3)
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
Also, react-app-rewired
directly fails when use command yarn start
, due to the same issue described above.
Issue Analytics
- State:
- Created 5 years ago
- Reactions:8
- Comments:10 (1 by maintainers)
Top Results From Across the Web
Cannot find module 'babel-loader' Require stack
I'm running this react app and then I ran npm eject to eject the app so I can add the web packs features....
Read more >Fix the Cannot find module '@babel/core' error - Reactgo
First, remove the node_modules folder, package-lock.json file present inside your project directory by using the below command. rm-rf ...
Read more >babel/preset-env
babel /preset-env` is a smart preset that allows you to use the latest JavaScript without needing to micromanage which syntax transforms (and optionally, ......
Read more >react-hot-loader - npm
Place it after babel-loader, if babel-loader is present. // webpack.config.js module.exports = { module: ...
Read more >internal modules cjs loader error - You.com | The AI Search ...
You need to install express as the error is showing that express is missing. The command for that shall be npm install express...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
A simple fix to that just install ‘babel-loader’ again by typing yarn add babel-loader on your terminal
I’ve just faced the exact same issue but I’m using npm as my package manager. update: I installed yarn and I’m still having the issue there. Although It can be solved by installing ‘babel-loader’ manually