Skip to content

What happens when you eject Create React App

Satendra Rai edited this page Oct 27, 2018 · 2 revisions

Create React App provides simple cli command to create application with the initial project structure, install dependencies and configure package.json scripts (run / build / test).

npm install -g create-react-app
create-react-app my-app
cd my-app/
npm start # yarn start

And there are no configuration. Developers can’t configure webpack, babel presets until ejection.

If you’re a power user and you aren’t happy with the default configuration, you can “eject” from the tool and use it as a boilerplate generator.

Running npm run eject copies all the configuration files and the transitive dependencies (Webpack, Babel, ESLint, etc) right into your project so you have full control over them.

Commands like npm start and npm run build will still work, but they will point to the copied scripts so you can tweak them. At this point, you’re on your own.


REFERENCE: https://medium.com/@tuchk4/why-i-love-create-react-app-e63b1be689a3

Clone this wiki locally