🔧 Replace Vite/Vitest with TypeScript 7 and node --test

- Use tsc 7 for build (vite no longer needed for a Node library)
- Use node --test with --experimental-strip-types for tests (vitest dropped)
- Use c8 for coverage instead of vitest's built-in coverage
- Add tsconfig.build.json separating typecheck from emit config
- Drop DOM lib, add strict noUncheckedIndexedAccess/noImplicitOverride
- Pin engines.node to >=22.6 (required for --experimental-strip-types)
- Update CI to Node 24 LTS (unflagged strip-types)
- Add @types/node for node:test / node:assert types
This commit is contained in:
tmu committed 2026-09-03 09:54:21 +00:00
1 parent cac1349c95
commit 3530262261
7 files changed
+3638 -7424

No files matched your search

+4 -10
View File
@@ -5,7 +5,7 @@ on:
branches: [main]
pull_request:
branches: [main]
workflow_dispatch:
workflow_dispatch: {}
jobs:
build:
@@ -14,18 +14,12 @@ jobs:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 20
node-version: 24
cache: "npm"
- run: npm ci
- run: npm run build
- run: npm run check
- run: npm run test:ci
- run: npm run check:outdated
- run: npm run check:cspell
- run: npm run check:tsc
- run: npm run check:eslint
- run: npm run check:prettier
- run: npm run check:package
- name: Upload coverage
uses: actions/upload-artifact@v4
with:
@@ -40,10 +34,10 @@ jobs:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 20
node-version: 24
registry-url: "https://registry.npmjs.org/"
- run: npm ci
- run: npm run build
- run: npm publish --access public
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}