diff --git a/docusaurus/docs/available-scripts.md b/docusaurus/docs/available-scripts.md index a6a32751926..23cc9b7d18b 100644 --- a/docusaurus/docs/available-scripts.md +++ b/docusaurus/docs/available-scripts.md @@ -28,8 +28,18 @@ See the section about [deployment](deployment.md) for more information. **Note: this is a one-way operation. Once you `eject`, you can’t go back!** -If you aren’t satisfied with the build tool and configuration choices, you can `eject` at any time. This command will remove the single build dependency from your project. +If you aren’t satisfied with the build tool and configuration choices, you can `eject` at any time. This command will remove the single build dependency from your project. -Instead, it will copy all the configuration files and the transitive dependencies (Webpack, Babel, ESLint, etc) right into your project so you have full control over them. All of the commands except `eject` will still work, but they will point to the copied scripts so you can tweak them. At this point you’re on your own. +Instead, it will copy all the configuration files and the transitive dependencies (Webpack, Babel, ESLint, etc) right into your project as dependencies in `package.json`. + +We put them all in dependencies because the distinction between dependencies and development dependencies is pretty arbitrary for front-end apps that produce static bundles. Technically you don't need any of these dependencies on the server, not even the runtime ones. So by that logic even `react` might be seen as a development dependency. + +We used to try to separate them but as explained above, it isn't really consistent in the first place. There's no technical reason why this distinction is useful for apps that have no Node runtime. + +In addition, it used to cause problems for some Heroku deployments that didn't install development dependencies (and thus weren't able to build the project on the server or test it right before deployment). + +You have full control over them and can always rearrange `package.json` as you deem reasonable. + +All of the commands except `eject` will still work, but they will point to the copied scripts so you can tweak them. At this point, you’re on your own. You don’t have to ever use `eject`. The curated feature set is suitable for small and middle deployments, and you shouldn’t feel obligated to use this feature. However we understand that this tool wouldn’t be useful if you couldn’t customize it when you are ready for it.