diff --git a/.github/ISSUE_TEMPLATE.md b/.github/ISSUE_TEMPLATE.md
deleted file mode 100644
index b489f0e6e61f..000000000000
--- a/.github/ISSUE_TEMPLATE.md
+++ /dev/null
@@ -1,7 +0,0 @@
-- [ ] Check the current issues to ensure you aren't creating a duplicate.
-- [ ] Consider making small typo fixes and such directly as pull requests.
-- [ ] For the voting application, go to https://github.com/webpack-contrib/voting-app.
-- [ ] For the document of Chinese translation(中文版文档), go to https://github.com/docschina/webpack.js.org.
-- [ ] For loader/plugin docs, consider opening an issue in the corresponding repository.
-- [ ] No existing issue? Go ahead and open a new one.
-- **Remove these instructions from your PR as they are for your eyes only.**
diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md
deleted file mode 100644
index fb181665c983..000000000000
--- a/.github/PULL_REQUEST_TEMPLATE.md
+++ /dev/null
@@ -1,11 +0,0 @@
-_describe your changes..._
-
-- [ ] Read and sign the [CLA][1]. PRs that haven't signed it won't be accepted.
-- [ ] Make sure your PR complies with the [writer's guide][2].
-- [ ] Review the diff carefully as sometimes this can reveal issues.
-- [ ] Do not abandon your Pull Request: [Stale Pull Requests][3].
-- **Remove these instructions from your PR as they are for your eyes only.**
-
-[1]: https://github.com/openjs-foundation/EasyCLA#openjs-foundation-cla
-[2]: https://webpack.js.org/contribute/writers-guide/
-[3]: https://webpack.js.org/contribute/#pull-requests
diff --git a/.github/workflows/build-pr.yml b/.github/workflows/build-pr.yml
new file mode 100644
index 000000000000..c473da562140
--- /dev/null
+++ b/.github/workflows/build-pr.yml
@@ -0,0 +1,35 @@
+# This is a basic workflow to help you get started with Actions
+
+name: CI PR
+
+# Controls when the action will run. Triggers the workflow on push or pull request
+# events but only for the master branch
+on:
+ push:
+ branches: [cn]
+
+# A workflow run is made up of one or more jobs that can run sequentially or in parallel
+jobs:
+ # This workflow contains a single job called "build"
+ build:
+ # The type of runner that the job will run on
+ runs-on: ubuntu-latest
+
+ # Steps represent a sequence of tasks that will be executed as part of the job
+ steps:
+ # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
+ - uses: actions/checkout@v2
+
+ - name: Install
+ run: |
+ yarn
+ yarn clean
+
+ - name: Build
+ run: |
+ yarn build
+
+ - name: Check Build
+ run: |
+ sudo -i
+ sudo chown -R $USER ./dist
diff --git a/.github/workflows/dependency-review.yml b/.github/workflows/dependency-review.yml
index 747b1fb03681..a25de591ba3c 100644
--- a/.github/workflows/dependency-review.yml
+++ b/.github/workflows/dependency-review.yml
@@ -1,14 +1,14 @@
-# name: 'Dependency Review'
-# on: [pull_request]
+name: 'Dependency Review'
+on: [pull_request]
-# permissions:
-# contents: read
+permissions:
+ contents: read
-# jobs:
-# dependency-review:
-# runs-on: ubuntu-latest
-# steps:
-# - name: 'Checkout Repository'
-# uses: actions/checkout@v4
-# - name: 'Dependency Review'
-# uses: actions/dependency-review-action@v3
+jobs:
+ dependency-review:
+ runs-on: ubuntu-latest
+ steps:
+ - name: 'Checkout Repository'
+ uses: actions/checkout@v3
+ - name: 'Dependency Review'
+ uses: actions/dependency-review-action@v2
diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml
index d6abae836fb5..c254eb5e33d0 100644
--- a/.github/workflows/deploy.yml
+++ b/.github/workflows/deploy.yml
@@ -1,9 +1,11 @@
+# The file need not be maintained in the cn repo.
+
name: Deploy
on:
push:
branches:
- - main
+ - master
schedule:
- cron: '0 0 * * *'
jobs:
@@ -12,10 +14,10 @@ jobs:
strategy:
matrix:
os: [ubuntu-latest]
- node-version: [latest]
+ node-version: [16.x]
runs-on: ${{ matrix.os }}
steps:
- - uses: actions/checkout@v4
+ - uses: actions/checkout@v3
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
@@ -41,7 +43,7 @@ jobs:
- run: yarn lint:links
- name: Deploy
- uses: JamesIves/github-pages-deploy-action@v4.4.3
+ uses: JamesIves/github-pages-deploy-action@v4.4.0
with:
token: ${{ secrets.GITHUB_TOKEN }}
folder: dist
diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml
index d5289e4ff56a..7e5b6a6d6bff 100644
--- a/.github/workflows/main.yml
+++ b/.github/workflows/main.yml
@@ -1,4 +1,4 @@
-# This is a basic workflow to help you get started with Actions
+# This file should modified carefully.
name: CI
@@ -18,7 +18,7 @@ jobs:
# Steps represent a sequence of tasks that will be executed as part of the job
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- - uses: actions/checkout@v4
+ - uses: actions/checkout@v2
- name: Install
run: |
diff --git a/package.json b/package.json
index 7556bd2d6471..debde1002f4b 100644
--- a/package.json
+++ b/package.json
@@ -28,15 +28,15 @@
"clean-printable": "rimraf src/content/**/printable.mdx",
"preclean": "run-s clean-dist clean-printable",
"clean": "rimraf src/content/**/_*.mdx src/**/_*.json repositories/*.json",
- "start": "npm run clean-dist && webpack serve --config webpack.dev.mjs --env dev --progress --define-process-env-node-env development",
+ "start": "npm run clean-dist && webpack serve --config webpack.dev.mjs --env dev --progress --node-env development",
"content": "node src/scripts/build-content-tree.mjs ./src/content ./src/_content.json",
- "bundle-analyze": "run-s clean fetch content && webpack --config webpack.prod.mjs --define-process-env-node-env production && run-s printable content && webpack --config webpack.ssg.mjs --define-process-env-node-env production --env ssg --profile --json > stats.json && webpack-bundle-analyzer stats.json",
+ "bundle-analyze": "run-s clean fetch content && webpack --config webpack.prod.mjs --node-env production && run-s printable content && webpack --config webpack.ssg.mjs --node-env production --env ssg --profile --json > stats.json && webpack-bundle-analyzer stats.json",
"fetch-repos": "node src/utilities/fetch-package-repos.mjs",
"fetch": "run-p fetch:*",
"fetch:readmes": "node src/utilities/fetch-package-readmes.mjs",
"fetch:supporters": "node src/utilities/fetch-supporters.mjs",
"prebuild": "npm run clean",
- "build": "run-s fetch-repos fetch content && webpack --config webpack.prod.mjs --define-process-env-node-env production && run-s printable content && webpack --config webpack.ssg.mjs --define-process-env-node-env production --env ssg",
+ "build": "run-s content && webpack --config webpack.prod.mjs --node-env production && run-s printable content && webpack --config webpack.ssg.mjs --node-env production --env ssg",
"postbuild": "npm run sitemap",
"build-test": "npm run build && http-server --port 4200 dist/",
"serve-dist": "http-server --port 4200 dist/",
@@ -48,6 +48,9 @@
"lint-markdown": "markdownlint --config ./.markdownlint.json",
"lint:prose": "vale --config='.vale.ini' src/content",
"lint:links": "hyperlink -c 8 --root dist -r dist/index.html --canonicalroot https://webpack.js.org/ --internal --skip /plugins/extract-text-webpack-plugin/ --skip /printable --skip https:// --skip http:// --skip sw.js > internal-links.tap; cat internal-links.tap | tap-spot",
+ "lint:heading": "textlint --fix src/content/*",
+ "lint:heading-blog": "textlint --fix src/content/blog/*",
+ "lint:headingMDX": "textlint --fix src/content/**/*.mdx",
"sitemap": "cd dist && sitemap-static --ignore-file=../sitemap-ignore.json --pretty --prefix=https://webpack.js.org/ > sitemap.xml",
"serve": "npm run build && sirv start ./dist --port 4000",
"preprintable": "npm run clean-printable",
@@ -70,97 +73,102 @@
]
},
"devDependencies": {
- "@babel/core": "^7.22.19",
- "@babel/eslint-parser": "^7.22.15",
+ "@babel/core": "^7.19.6",
+ "@babel/eslint-parser": "^7.19.1",
"@babel/plugin-proposal-class-properties": "^7.17.12",
- "@babel/preset-env": "^7.22.15",
- "@babel/preset-react": "^7.22.15",
+ "@babel/preset-env": "^7.19.4",
+ "@babel/preset-react": "^7.18.6",
"@mdx-js/loader": "^2.0.0-next.9",
- "@octokit/auth-action": "^4.0.0",
- "@octokit/rest": "^20.0.1",
+ "@octokit/auth-action": "^2.0.2",
+ "@octokit/rest": "^19.0.5",
"@pmmmwh/react-refresh-webpack-plugin": "next",
- "@svgr/webpack": "^8.1.0",
- "autoprefixer": "^10.4.15",
- "babel-loader": "^9.1.3",
+ "@svgr/webpack": "^6.5.1",
+ "autoprefixer": "^10.4.13",
+ "babel-loader": "^9.0.0",
"copy-webpack-plugin": "^11.0.0",
- "css-loader": "^6.8.1",
- "css-minimizer-webpack-plugin": "^5.0.1",
- "cypress": "^13.2.0",
- "directory-tree": "^3.5.1",
+ "css-loader": "^6.7.1",
+ "css-minimizer-webpack-plugin": "^4.2.2",
+ "cypress": "^10.11.0",
+ "directory-tree": "^3.3.1",
"directory-tree-webpack-plugin": "^1.0.3",
"duplexer": "^0.1.1",
- "eslint": "^8.49.0",
- "eslint-config-prettier": "^9.0.0",
- "eslint-plugin-cypress": "^2.14.0",
- "eslint-plugin-mdx": "^2.2.0",
- "eslint-plugin-react": "^7.33.2",
+ "eslint": "^8.26.0",
+ "eslint-config-prettier": "^8.5.0",
+ "eslint-plugin-cypress": "^2.12.1",
+ "eslint-plugin-mdx": "^2.0.5",
+ "eslint-plugin-react": "^7.31.10",
"eslint-plugin-react-hooks": "^4.6.0",
"front-matter": "^4.0.2",
"github-slugger": "^2.0.0",
- "html-webpack-plugin": "^5.5.3",
+ "html-loader": "^2.1.2",
+ "html-webpack-plugin": "^5.5.0",
"http-server": "^14.1.1",
- "husky": "^8.0.3",
+ "husky": "^8.0.1",
"hyperlink": "^5.0.4",
"jest": "^29.7.0",
- "lightningcss": "^1.21.8",
- "lint-staged": "^14.0.1",
+ "lightningcss": "^1.16.0",
+ "lint-staged": "^13.0.3",
"lodash": "^4.17.21",
- "markdownlint-cli": "^0.36.0",
- "mdast-util-to-string": "^4.0.0",
- "mini-css-extract-plugin": "^2.7.6",
- "mkdirp": "^3.0.1",
+ "markdownlint": "^0.26.2",
+ "markdownlint-cli": "^0.32.2",
+ "mdast-util-to-string": "^3.1.0",
+ "mini-css-extract-plugin": "^2.6.1",
+ "mkdirp": "^1.0.4",
"modularscale-sass": "^3.0.3",
+ "node-fetch": "^3.2.10",
"npm-run-all": "^4.1.1",
- "postcss": "^8.4.29",
- "postcss-loader": "^7.3.3",
- "prettier": "^3.0.3",
+ "postcss": "^8.4.18",
+ "postcss-loader": "^7.0.1",
+ "prettier": "^2.7.1",
"react-refresh": "^0.14.0",
"redirect-webpack-plugin": "^1.0.0",
- "remark": "^14.0.3",
+ "remark": "^14.0.2",
"remark-autolink-headings": "7.0.1",
- "remark-emoji": "^4.0.0",
+ "remark-emoji": "^3.0.2",
"remark-extract-anchors": "1.1.1",
"remark-frontmatter": "^4.0.1",
"remark-gfm": "^1.0.0",
- "remark-html": "^15.0.2",
+ "remark-html": "^15.0.1",
"remark-refractor": "montogeek/remark-refractor",
- "rimraf": "^5.0.1",
- "sass": "^1.67.0",
- "sass-loader": "^13.3.2",
+ "rimraf": "^3.0.2",
+ "sass": "^1.55.0",
+ "sass-loader": "^13.1.0",
"sirv-cli": "^2.0.2",
"sitemap-static": "^0.4.2",
"static-site-generator-webpack-plugin": "^3.4.1",
- "style-loader": "^3.3.3",
- "tailwindcss": "^3.3.3",
+ "style-loader": "^3.3.1",
+ "tailwindcss": "^3.2.1",
"tap-spot": "^1.1.2",
- "unist-util-visit": "^5.0.0",
- "webpack": "^5.88.2",
- "webpack-bundle-analyzer": "^4.9.1",
- "webpack-cli": "^5.1.4",
- "webpack-dev-server": "^4.15.1",
- "webpack-merge": "^5.9.0",
- "workbox-webpack-plugin": "^7.0.0",
- "yarn-deduplicate": "^6.0.2"
+ "textlint": "^11.8.2",
+ "textlint-rule-heading": "^1.0.10",
+ "unist-util-visit": "^4.1.1",
+ "webpack": "^5.74.0",
+ "webpack-bundle-analyzer": "^4.7.0",
+ "webpack-cli": "^4.10.0",
+ "webpack-dev-server": "^4.11.1",
+ "webpack-merge": "^5.8.0",
+ "workbox-webpack-plugin": "^6.5.4",
+ "yarn-deduplicate": "^6.0.0"
},
"dependencies": {
"@docsearch/react": "^3.0.0-alpha.50",
- "@react-spring/web": "^9.7.3",
"path-browserify": "^1.0.1",
"prop-types": "^15.8.1",
"react": "^17.0.2",
"react-dom": "^17.0.2",
"react-helmet-async": "^1.3.0",
- "react-router-dom": "^6.16.0",
+ "react-router-dom": "^6.4.2",
+ "react-spring": "^9.5.5",
"react-tiny-popover": "5",
"react-use": "^17.4.0",
"react-visibility-sensor": "^5.0.2",
"webpack-pwa-manifest": "^4.3.0",
- "workbox-window": "^7.0.0"
+ "webpack.vote": "https://github.com/webpack/voting-app.git",
+ "workbox-window": "^6.5.4"
},
"resolutions": {
"sitemap-static/minimist": "1.2.5",
"ini": "1.3.7",
- "eval": "^0.1.5",
- "markdownlint-cli/markdownlint": "^0.27.0"
+ "eval": "^0.1.5"
}
}
diff --git a/src/components/HelloDarkness.jsx b/src/components/HelloDarkness.jsx
index 798e783e2fde..4396a11dd228 100644
--- a/src/components/HelloDarkness.jsx
+++ b/src/components/HelloDarkness.jsx
@@ -52,7 +52,7 @@ export default function HelloDarkness() {
xmlns="http://www.w3.org/2000/svg"
>