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: .github/CONTRIBUTING.md
+10-12Lines changed: 10 additions & 12 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -8,8 +8,7 @@ page please create an issue first.
8
8
9
9
Start by ensuring that you have Node.js installed and forking the repository:
10
10
11
-
- Install [Node.js][1] if you have not already.
12
-
- Install [Yarn][13] if you have not already. Yarn is an alternative to npm, and it is required for building the site as we use `yarn` specific features like `resolutions` which are not available in other package managers like `pnpm`.
11
+
- Install [Node.js][1] if you have not already. npm ships with Node.js, so no separate package manager installation is required.
13
12
- Fork the **webpack.js.org** repo from [the main repository][2].
14
13
-`git clone <your-clone-url> && cd webpack.js.org`
15
14
@@ -21,18 +20,18 @@ Start by ensuring that you have Node.js installed and forking the repository:
21
20
22
21
Once you are in the project directory, run the following commands:
23
22
24
-
-`yarn` to pull all dependencies.
25
-
-`GITHUB_TOKEN=<your-token-here> yarn fetch-all` - Fetches all updated website content from GitHub.
26
-
-`yarn build` to create a production version of the site.
27
-
-`yarn start` to develop on a local webpack-dev-server: [localhost:3000][3].
23
+
-`npm install` to pull all dependencies.
24
+
-`GITHUB_TOKEN=<your-token-here> npm run fetch-all` - Fetches all updated website content from GitHub.
25
+
-`npm run build` to create a production version of the site.
26
+
-`npm start` to develop on a local webpack-dev-server: [localhost:3000][3].
28
27
29
28
**Note:** The `fetch` and `fetch-repos` commands must be run before building the site as they populate necessary data for the build process.
30
29
31
-
> NOTE: run `yarn fetch-repos` and then `yarn fetch` before running `yarn start` command for the first time
30
+
> NOTE: run `npm run fetch-repos` and then `npm run fetch` before running `npm start` command for the first time
32
31
33
-
-`yarn fetch` to retrieve external documentation/data.
32
+
-`npm run fetch` to retrieve external documentation/data.
34
33
35
-
The final command, `yarn fetch`, is optional as both `yarn build` and `yarn start`
34
+
The final command, `npm run fetch`, is optional as both `npm run build` and `npm start`
36
35
will do this automatically. This step pulls in documentation for loaders/plugins hosted
37
36
in separate repositories such as the ones found in the [webpack-contrib][4] organization.
38
37
See the `package.json` for the full list of `scripts`.
@@ -60,13 +59,13 @@ you've [installed the plugin][7] if your text editor needs one.
60
59
Run the full test suite (lint + Jest) with:
61
60
62
61
```bash
63
-
yarntest
62
+
npmtest
64
63
```
65
64
66
65
To run only Jest tests:
67
66
68
67
```bash
69
-
yarn jest
68
+
npm run jest
70
69
```
71
70
72
71
To update snapshots after intentional UI changes:
@@ -148,5 +147,4 @@ any time spent fixing typos or clarifying sections in the documentation.
0 commit comments