Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 18 additions & 10 deletions .github/workflows/node.js.yml → .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
# This workflow will do a clean installation of node dependencies, cache/restore them, build the source code and run tests across different versions of node
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-nodejs

name: Node.js CI

Expand All @@ -10,21 +9,30 @@ on:
branches: [ "main" ]

jobs:
build:

lint:
runs-on: ubuntu-latest

strategy:
matrix:
node-version: [18.x, 20.x, 22.x]
steps:
- uses: actions/checkout@v4
- name: Use Node.js LTS
uses: actions/setup-node@v4
with:
node-version: 'lts/*'
cache: 'npm'
- run: npm ci
- name: Run ESLint
run: npm run lint

test:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4
- name: Use Node.js ${{ matrix.node-version }}
- name: Use Node.js LTS
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
node-version: 'lts/*'
cache: 'npm'
- run: npm ci
- run: npm run build --if-present
- run: npm test
- name: Run tests
run: npm test
2 changes: 1 addition & 1 deletion eslint.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ export default [
{ languageOptions: { globals: globals.browser } },
pluginJs.configs.recommended,
{
ignores: ["**/node_modules/", "examples/**, test/**"],
languageOptions: {
ecmaVersion: 'latest',
globals: {
Expand All @@ -16,4 +15,5 @@ export default [
},
},
},
{ ignores: ["examples/", "node_modules/", "coverage/", "test/"], },
];