diff --git a/.changeset/node-22-support.md b/.changeset/node-22-support.md new file mode 100644 index 0000000..19120f7 --- /dev/null +++ b/.changeset/node-22-support.md @@ -0,0 +1,8 @@ +--- +'@seamless-auth/core': patch +'@seamless-auth/express': patch +'@seamless-auth/fastify': patch +'@seamless-auth/nextjs': patch +--- + +Support Node 22 and newer. The `engines` field now requires `>=22` instead of `>=24 <25`, and CI runs on Node 22, 24, and the latest release (fells-code/seamless-auth-api#339). diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index f0e2e54..7efce16 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -8,9 +8,16 @@ on: jobs: test: - name: Run Tests + name: Run Tests (Node ${{ matrix.node-version }}) runs-on: ubuntu-latest + strategy: + fail-fast: false + matrix: + # The supported range is engines >=22: the oldest supported LTS, the + # development default from .nvmrc, and the newest release. + node-version: [22, 24, latest] + steps: - uses: actions/checkout@v4 @@ -20,7 +27,7 @@ jobs: - uses: actions/setup-node@v4 with: - node-version-file: '.nvmrc' + node-version: ${{ matrix.node-version }} cache: pnpm - name: Install dependencies diff --git a/AGENTS.md b/AGENTS.md index 0506b45..19c7c73 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -106,8 +106,9 @@ packages/ | Build | `pnpm build` | | Test | `pnpm test` | -- Node version is pinned by `.nvmrc` (Node 24); CI reads it via - `node-version-file`. Run `nvm use` and `corepack enable` locally to match. +- Supported Node is `>=22`. CI tests 22, 24, and the latest release; + `.nvmrc` pins Node 24 for development and releases. Run `nvm use` and + `corepack enable` locally. - Releases use Changesets; a user-facing change needs a changeset. Do not hand-edit versions or `CHANGELOG.md`. diff --git a/package.json b/package.json index f980ab7..04d86c4 100644 --- a/package.json +++ b/package.json @@ -4,7 +4,7 @@ "private": true, "packageManager": "pnpm@10.33.0", "engines": { - "node": ">=24 <25" + "node": ">=22" }, "scripts": { "build": "pnpm -r --sort build", diff --git a/packages/core/package.json b/packages/core/package.json index 27f7703..8d63035 100644 --- a/packages/core/package.json +++ b/packages/core/package.json @@ -41,7 +41,7 @@ "README.md" ], "engines": { - "node": ">=24 <25" + "node": ">=22" }, "scripts": { "build": "tsc -p tsconfig.json", diff --git a/packages/express/package.json b/packages/express/package.json index 34cc68b..618683b 100644 --- a/packages/express/package.json +++ b/packages/express/package.json @@ -30,7 +30,7 @@ } }, "engines": { - "node": ">=24 <25" + "node": ">=22" }, "scripts": { "build": "pnpm run build:js && pnpm run build:types", diff --git a/packages/fastify/package.json b/packages/fastify/package.json index 148f439..4320731 100644 --- a/packages/fastify/package.json +++ b/packages/fastify/package.json @@ -30,7 +30,7 @@ } }, "engines": { - "node": ">=24 <25" + "node": ">=22" }, "scripts": { "build": "pnpm run build:js && pnpm run build:types", diff --git a/packages/nextjs/package.json b/packages/nextjs/package.json index 353714e..38c2f91 100644 --- a/packages/nextjs/package.json +++ b/packages/nextjs/package.json @@ -31,7 +31,7 @@ } }, "engines": { - "node": ">=24 <25" + "node": ">=22" }, "scripts": { "build": "pnpm run build:js && pnpm run build:types",