diff --git a/.github/CONTRIBUTING.md b/.github/CONTRIBUTING.md index 0d6ff2557..353fb95bb 100644 --- a/.github/CONTRIBUTING.md +++ b/.github/CONTRIBUTING.md @@ -11,6 +11,10 @@ We welcome any type of contribution, not only code. You can help with - **Community**: presenting the project at meetups, organizing a dedicated meetup for the local community, ... - **Code**: take a look at the [open issues](https://github.com/HTMLHint/HTMLHint/issues). Even if you can't write code, commenting on them, showing that you care about a given issue matters. It helps us triage them. +## Development setup + +Use Node.js 20 or later (the repo pins a version with [Volta](https://volta.sh/) in `package.json`). + ## Submitting code Any code change should be submitted as a pull request. The description should explain what the code does and give steps to execute it. The pull request should also contain tests. diff --git a/.github/copilot-instructions.md b/.github/copilot-instructions.md index a2c8fbd26..726fdf5ef 100644 --- a/.github/copilot-instructions.md +++ b/.github/copilot-instructions.md @@ -6,7 +6,7 @@ - All code should be formatted with Prettier. - Use ESLint to check for JavaScript errors. - Rollup is used for building the project. -- Node v20 is used for development. +- Node.js 20 or newer is required; Volta pins the repo to Node 20 LTS in `package.json`. - Core code is in TypeScript v5.4.5. - All new rules for HTMLHint should be placed in the rules directory. - Tests for new rules should be added in rules and follow the naming pattern `.spec.js`. diff --git a/.github/workflows/ossf-scorecard.yml b/.github/workflows/ossf-scorecard.yml index 364c76274..2ab0441da 100644 --- a/.github/workflows/ossf-scorecard.yml +++ b/.github/workflows/ossf-scorecard.yml @@ -7,6 +7,10 @@ on: push: branches: ['main'] +concurrency: + group: scorecard-${{ github.ref }} + cancel-in-progress: true + permissions: read-all jobs: diff --git a/.github/workflows/spellcheck.yml b/.github/workflows/spellcheck.yml index 26be0cfab..554674c3a 100644 --- a/.github/workflows/spellcheck.yml +++ b/.github/workflows/spellcheck.yml @@ -6,6 +6,10 @@ on: pull_request: branches: [main] +concurrency: + group: spellcheck-${{ github.ref }} + cancel-in-progress: true + permissions: contents: read diff --git a/.github/workflows/super-linter.yml b/.github/workflows/super-linter.yml index 3ba6dc9f8..c6e0cb1dd 100644 --- a/.github/workflows/super-linter.yml +++ b/.github/workflows/super-linter.yml @@ -9,6 +9,10 @@ on: branches-ignore: - 'dependabot/**' +concurrency: + group: super-linter-${{ github.event.pull_request.number || github.ref }} + cancel-in-progress: true + permissions: contents: read diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index f3a447e0b..d92dc3f66 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -43,7 +43,6 @@ jobs: fail-fast: false matrix: node: - - 18 - 20 - 22 - 24 diff --git a/.nvmrc b/.nvmrc index 9a2a0e219..018b52d01 100644 --- a/.nvmrc +++ b/.nvmrc @@ -1 +1 @@ -v20 +v20.20.1 diff --git a/README.md b/README.md index 2db67eeb7..fc1acf41c 100644 --- a/README.md +++ b/README.md @@ -38,6 +38,8 @@ ## 📟 Installation and Usage +HTMLHint requires [Node.js](https://nodejs.org/) 20 or later. + There are two ways to install HTMLHint: globally and locally. ### Local Installation and Usage diff --git a/package-lock.json b/package-lock.json index 204add7b2..345a84f24 100644 --- a/package-lock.json +++ b/package-lock.json @@ -42,7 +42,7 @@ "typescript": "5.4.5" }, "engines": { - "node": ">=18" + "node": ">=20" }, "funding": { "type": "Open Collective", diff --git a/package.json b/package.json index c7b8d9773..27cfb8758 100644 --- a/package.json +++ b/package.json @@ -79,9 +79,9 @@ "typescript": "5.4.5" }, "engines": { - "node": ">=18" + "node": ">=20" }, "volta": { - "node": "18.20.8" + "node": "20.20.1" } } diff --git a/website/src/content/docs/getting-started.mdx b/website/src/content/docs/getting-started.mdx index 4c9046238..817c9459e 100644 --- a/website/src/content/docs/getting-started.mdx +++ b/website/src/content/docs/getting-started.mdx @@ -5,6 +5,8 @@ description: How to set up HTMLHint in your project by adding it as a dev depend import { Tabs, TabItem } from '@astrojs/starlight/components'; +HTMLHint requires Node.js 20 or later. + 1\. Use npm or yarn to install HTMLHint: