Skip to content
This repository was archived by the owner on Feb 22, 2026. It is now read-only.

Commit efd87db

Browse files
committed
chore: modernize for workers
1 parent 7855ac9 commit efd87db

11 files changed

Lines changed: 13973 additions & 77 deletions

File tree

.github/workflows/lint.yml

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ jobs:
1616
strategy:
1717
fail-fast: false
1818
matrix:
19-
node-version: [20.x]
19+
node-version: [24.x]
2020

2121
steps:
2222
- name: Checkout Source Files
@@ -25,7 +25,12 @@ jobs:
2525
- name: Setup pnpm
2626
uses: pnpm/action-setup@v3
2727
with:
28-
version: 9
28+
version: 10
29+
30+
- name: Setup Node.js
31+
uses: actions/setup-node@1d0ff469b7ec7b3cb9d8673fde0c81c44821de2a # v4
32+
with:
33+
node-version: ${{ matrix.node-version }}
2934

3035
- name: Lint Source Files
3136
run: |

.github/workflows/playwright.yml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,11 +13,15 @@ jobs:
1313
runs-on: ubuntu-latest
1414
steps:
1515
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
16+
- name: Setup pnpm
17+
uses: pnpm/action-setup@v3
18+
with:
19+
version: 10
1620
- uses: actions/setup-node@1d0ff469b7ec7b3cb9d8673fde0c81c44821de2a # v4
1721
with:
18-
node-version: 20.x
22+
node-version: 24.x
1923
- name: Install dependencies
20-
run: npm install -g pnpm && pnpm install
24+
run: pnpm install
2125
- name: Install Playwright Browsers
2226
run: pnpm exec playwright install --with-deps
2327
- name: Run Playwright tests

.github/workflows/react-tests.yml

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,12 @@ jobs:
1313
- name: Setup pnpm
1414
uses: pnpm/action-setup@v3
1515
with:
16-
version: 9
16+
version: 10
17+
18+
- name: Setup Node.js
19+
uses: actions/setup-node@1d0ff469b7ec7b3cb9d8673fde0c81c44821de2a # v4
20+
with:
21+
node-version: 24.x
1722

1823
- name: Install dependencies
1924
run: pnpm install

.nvmrc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
20.18.3
1+
24

.wrangler/deploy/config.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
{ "configPath": "../../dist/wrangler.json", "auxiliaryWorkers": [] }

Dockerfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
ARG BASE_REGISTRY=docker.io
22
ARG BASE_IMAGE=node
3-
ARG BASE_TAG=22-alpine
3+
ARG BASE_TAG=24-alpine
44

55
FROM ${BASE_REGISTRY}/${BASE_IMAGE}:${BASE_TAG}
66

77
# Install git for pnpm -> yarn interop dependencies
88
RUN apk add --no-cache git
99
# Install pnpm package manager globally
10-
RUN npm install -g pnpm@9
10+
RUN npm install -g pnpm@10
1111

1212
# Create app directory
1313
WORKDIR /usr/src/app

package.json

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
"description": "This is a free quiz site made for developers by freeCodeCamp",
55
"version": "0.1.0",
66
"private": true,
7-
"packageManager": "pnpm@9.15.4",
7+
"packageManager": "pnpm@10.30.1",
88
"dependencies": {
99
"@testing-library/jest-dom": "^6.4.6",
1010
"@testing-library/react": "^16.0.0",
@@ -29,6 +29,8 @@
2929
"fix-style": "pnpm run lint --fix",
3030
"lint-style": "prettier --list-different .",
3131
"format": "prettier --write \"**/*.{ts,tsx,json}\"",
32+
"deploy": "vite build && wrangler deploy",
33+
"preview:worker": "vite build && wrangler dev",
3234
"prepare": "husky install"
3335
},
3436
"eslintConfig": {
@@ -50,13 +52,15 @@
5052
]
5153
},
5254
"devDependencies": {
55+
"@cloudflare/vite-plugin": "^1.25.2",
56+
"@cloudflare/workers-types": "^4.20260228.0",
5357
"@playwright/test": "^1.45.3",
54-
"@types/node": "^20.0.0",
58+
"@types/node": "^24.10.13",
5559
"@types/react": "^18.3.3",
5660
"@types/react-dom": "^18.0.4",
5761
"@typescript-eslint/eslint-plugin": "^7.0.0",
5862
"@typescript-eslint/parser": "^7.0.0",
59-
"@vitejs/plugin-react": "^4.3.1",
63+
"@vitejs/plugin-react": "^4",
6064
"eslint": "^8.16.0",
6165
"eslint-config-prettier": "^9.0.0",
6266
"eslint-plugin-react": "^7.34.3",
@@ -66,9 +70,10 @@
6670
"prettier": "^3.0.0",
6771
"pretty-quick": "^4.0.0",
6872
"typescript": "^5.5.3",
69-
"vite": "^5.3.2",
73+
"vite": "^6.4.1",
7074
"vite-tsconfig-paths": "^4.2.2",
71-
"vitest": "^2.0.0"
75+
"vitest": "^2.0.0",
76+
"wrangler": "^4.67.0"
7277
},
7378
"lint-staged": {
7479
"*.ts": "eslint",

0 commit comments

Comments
 (0)