Skip to content

Commit 3b6f63f

Browse files
authored
deps: Upgrade to Node 22 (#2274)
- Upgrades build to use Node 22 - Adds version matrix to GH workflow to test compatibility with 20
1 parent 71a83bb commit 3b6f63f

File tree

8 files changed

+16
-14
lines changed

8 files changed

+16
-14
lines changed

.github/workflows/frontend-build-prepare.yaml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,9 @@ on:
1010
jobs:
1111
setup-and-build:
1212
runs-on: ubuntu-latest
13+
strategy:
14+
matrix:
15+
node: [20, 22]
1316

1417
steps:
1518
# Setup:
@@ -21,7 +24,7 @@ jobs:
2124
- name: Setup Node
2225
uses: actions/setup-node@v4
2326
with:
24-
node-version: '18'
27+
node-version: ${{ matrix.node }}
2528
cache: 'yarn'
2629
cache-dependency-path: frontend/yarn.lock
2730

.github/workflows/ui-tests-playwright.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ jobs:
2525
- name: Setup Node
2626
uses: actions/setup-node@v4
2727
with:
28-
node-version: '20'
28+
node-version: '22'
2929
cache: 'yarn'
3030
cache-dependency-path: frontend/yarn.lock
3131

.github/workflows/weblate-reformat.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ jobs:
2727
- name: Setup Node
2828
uses: actions/setup-node@v4
2929
with:
30-
node-version: '18'
30+
node-version: '22'
3131
cache: 'yarn'
3232
cache-dependency-path: frontend/yarn.lock
3333
- name: Install dependencies

frontend/.yarnrc

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +0,0 @@
1-
ignore-engines true

frontend/Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# syntax=docker/dockerfile:1.4
2-
FROM --platform=$BUILDPLATFORM docker.io/library/node:18 as build_deps
2+
FROM --platform=$BUILDPLATFORM docker.io/library/node:22 as build_deps
33

44
WORKDIR /app
55
COPY .yarnrc yarn.lock package.json ./

frontend/docs/docs/develop/frontend-dev.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,15 +10,15 @@ Instead of rebuilding the entire frontend image to view your UI changes, you can
1010

1111
The frontend development server requires an existing backend that has been deployed locally or is in production. See [Deploying Browsertrix](../deploy/index.md).
1212

13-
### 2. Node.js ≥18
13+
### 2. Node.js ≥20
1414

1515
To check if you already have Node.js installed, run the following command in your command line terminal:
1616

1717
```sh
1818
node --version
1919
```
2020

21-
You should see a version number like `v18.12.1`. If you see a command line error instead of a version number, [install Node.js](https://nodejs.org/en/download/package-manager) before continuing.
21+
You should see a version number like `v20.17.0`. If you see a command line error instead of a version number, [install Node.js](https://nodejs.org/en/download/package-manager) before continuing.
2222

2323
??? question "What if my other project requires a different version of Node.js?"
2424

frontend/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -138,7 +138,7 @@
138138
}
139139
},
140140
"engines": {
141-
"node": ">=18"
141+
"node": ">=20 <23"
142142
},
143143
"resolutions": {
144144
"**/playwright": "1.49.0",

frontend/tailwind.config.js

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
1-
const theme = require("@webrecorder/hickory/tokens/tailwind");
2-
const { tailwindTransform } = require("postcss-lit");
1+
import theme from "@webrecorder/hickory/tokens/tailwind";
2+
import { tailwindTransform } from "postcss-lit";
33

4-
const attributes = require("./config/tailwind/plugins/attributes");
5-
const containPlugin = require("./config/tailwind/plugins/contain");
6-
const contentVisibilityPlugin = require("./config/tailwind/plugins/content-visibility");
7-
const cssPartsPlugin = require("./config/tailwind/plugins/parts");
4+
import attributes from "./config/tailwind/plugins/attributes";
5+
import containPlugin from "./config/tailwind/plugins/contain";
6+
import contentVisibilityPlugin from "./config/tailwind/plugins/content-visibility";
7+
import cssPartsPlugin from "./config/tailwind/plugins/parts";
88

99
/**
1010
* Merge Shoelace and hickory themes

0 commit comments

Comments
 (0)