You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardexpand all lines: CONTRIBUTING.md
+11-9
Original file line number
Diff line number
Diff line change
@@ -90,24 +90,26 @@ All functionality must be retained (and configuration given to the user) if they
90
90
91
91
## Setting Up a Local Copy
92
92
93
+
You will need `npm@7` and `yarn@1` in order to bootstrap and test a local copy of this repo.
94
+
93
95
1. Clone the repo with `git clone https://github.com/facebook/create-react-app`
94
96
95
-
2. Run `yarn` in the root `create-react-app` folder.
97
+
2. Run `npm install` in the root `create-react-app` folder.
96
98
97
-
Once it is done, you can modify any file locally and run `yarn start`, `yarn test` or `yarn build` like you can in a generated project. It will serve the application from the files located in `packages/cra-template/template`.
99
+
Once it is done, you can modify any file locally and run `npm start`, `npm test` or `npm run build` like you can in a generated project. It will serve the application from the files located in `packages/cra-template/template`.
98
100
99
101
If you want to try out the end-to-end flow with the global CLI, you can do this too:
100
102
101
103
```sh
102
-
yarn create-react-app my-app
104
+
npx create-react-app my-app
103
105
cd my-app
104
106
```
105
107
106
-
and then run `yarn start` or `yarn build`.
108
+
and then run `npm start` or `npm run build`.
107
109
108
110
## Contributing to E2E (end to end) tests
109
111
110
-
**TL;DR** use the command `yarn e2e:docker` to run unit and e2e tests.
112
+
**TL;DR** use the command `npm run e2e:docker` to run unit and e2e tests.
111
113
112
114
More detailed information are in the dedicated [README](/test/README.md).
113
115
@@ -143,11 +145,11 @@ By default git would use `CRLF` line endings which would cause the scripts to fa
143
145
2. Close the milestone and create a new one for the next release.
144
146
3. In most releases, only `react-scripts` needs to be released. If you don’t have any changes to the `packages/create-react-app` folder, you don’t need to bump its version or publish it (the publish script will publish only changed packages).
145
147
4. Note that files in `packages/create-react-app` should be modified with extreme caution. Since it’s a global CLI, any version of `create-react-app` (global CLI) including very old ones should work with the latest version of `react-scripts`.
146
-
5. Run `yarn compile:lockfile`. The command will generate an updated lockfile in `packages/create-react-app` that should be committed.
148
+
5. Run `npm run compile:lockfile`. The command will generate an updated lockfile in `packages/create-react-app` that should be committed.
147
149
6. Create a change log entry for the release:
148
150
149
151
- You'll need an [access token for the GitHub API](https://help.github.com/articles/creating-an-access-token-for-command-line-use/). Save it to this environment variable: `export GITHUB_AUTH="..."`
150
-
- Run `yarn changelog`. The command will find all the labeled pull requests merged since the last release and group them by the label and affected packages, and create a change log entry with all the changes and links to PRs and their authors. Copy and paste it to `CHANGELOG.md`.
152
+
- Run `npm run changelog`. The command will find all the labeled pull requests merged since the last release and group them by the label and affected packages, and create a change log entry with all the changes and links to PRs and their authors. Copy and paste it to `CHANGELOG.md`.
151
153
- Add a four-space indented paragraph after each non-trivial list item, explaining what changed and why. For each breaking change also write who it affects and instructions for migrating existing code.
152
154
- Maybe add some newlines here and there. Preview the result on GitHub to get a feel for it. Changelog generator output is a bit too terse for my taste, so try to make it visually pleasing and well grouped.
153
155
@@ -161,9 +163,9 @@ Make sure to test the released version! If you want to be extra careful, you can
161
163
## Releasing the Docs
162
164
163
165
1. Go to the `docusaurus/website` directory
164
-
2. Run `yarn build`
166
+
2. Run `npm run build`
165
167
3. You'll need an [access token for the GitHub API](https://help.github.com/articles/creating-an-access-token-for-command-line-use/). Save it to this environment variable: `export GITHUB_AUTH="..."`
166
-
4. Run `GIT_USER=<GITHUB_USERNAME> CURRENT_BRANCH=main USE_SSH=true yarn deploy`
168
+
4. Run `GIT_USER=<GITHUB_USERNAME> CURRENT_BRANCH=main USE_SSH=true npm run deploy`
0 commit comments