Skip to content

Commit

Permalink
Update to Node 22 (active LTS)
Browse files Browse the repository at this point in the history
Include a refinement of how to use Node in the development instructions, avoid writing the Node/Python version multiple times.

- See https://nodejs.org/en/blog/release/v22.11.0
- See wagtail/wagtail#12531
  • Loading branch information
lb- committed Nov 4, 2024
1 parent 7b03f19 commit fd92e37
Show file tree
Hide file tree
Showing 7 changed files with 11 additions and 10 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ jobs:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: '20'
node-version: '22'
cache: 'npm'
- uses: actions/setup-python@v5
with:
Expand All @@ -36,7 +36,7 @@ jobs:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: '20'
node-version: '22'
cache: 'npm'
- uses: actions/setup-python@v5
with:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:

- uses: actions/setup-node@v4
with:
node-version: 20
node-version: '22'
cache: npm

- name: Install Node dependencies
Expand Down
2 changes: 1 addition & 1 deletion .nvmrc
Original file line number Diff line number Diff line change
@@ -1 +1 @@
20
22
2 changes: 1 addition & 1 deletion .readthedocs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ build:
os: ubuntu-22.04
tools:
python: '3.12'
nodejs: '20'
nodejs: '22'
jobs:
post_install:
- make install-frontend
Expand Down
7 changes: 4 additions & 3 deletions docs/development.rst
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,9 @@ Development
===========


For local development you need a system with Node v20.x, Python3, and Git.
It is strongly recommended to use a Python virtual environment (`venv`_).
For local development you need a system with Node v22.x, Python3, and Git.
It is strongly recommended to use a Python virtual environment (`venv`_) and
you use `fnm <https://github.com/Schniz/fnm>`_ to manage your Node versions.
The build process derives the version from repository data, so it's necessary
to clone the repository and not just download a single snapshot.

Expand Down Expand Up @@ -81,7 +82,7 @@ rather than using the shortcuts in the Makefile. Assume the commands below are
all run in PowerShell. These instructions will also work on Mac or Linux without
make installed as well.

First, be sure to install Python 3, and Node 20.
First, be sure to install Python, and Node.
`fnm <https://github.com/Schniz/fnm>`_ is really useful for
managing multiple versions of Node on Windows.

Expand Down
2 changes: 1 addition & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@
"lint": "npm run lint:js && npm run lint:css"
},
"engines": {
"node": ">=20"
"node": ">=22"
},
"prettier": {
"singleQuote": true,
Expand Down

0 comments on commit fd92e37

Please sign in to comment.