alphagov / govuk-frontend-docs

Technical documentation for GOV.UK Frontend
https://frontend.design-system.service.gov.uk/
33 stars 11 forks source link

Allow Node.js LTS ‘Iron’ (v20) release version #363

Closed colinrotherham closed 8 months ago

colinrotherham commented 8 months ago

This PR allows Node.js LTS ‘Iron’ (v20) to install dependencies for GOV.UK Frontend Docs

GOV.UK Frontend requires Node.js version 12.17.0 or later to support ECMAScript modules. Where possible, we recommend you install the latest Long Term Support (LTS) version.

Changes included:

  1. Updating .nvmrc for Node.js 20 So tools like nvm and asdf allow the lts/iron LTS release

  2. Add the package.json engines.node range Ensures npm install and other scripts check the local Node.js version is allowed

  3. Add the package.json engines.npm range Ensure support for npm@10 rather than npm@9

netlify[bot] commented 8 months ago

Deploy Preview for govuk-frontend-docs-preview ready!

Name Link
Latest commit ca28f249af1e8d1371b3488d78755d9e0e9db309
Latest deploy log https://app.netlify.com/sites/govuk-frontend-docs-preview/deploys/654235332056c30008d962fd
Deploy Preview https://deploy-preview-363--govuk-frontend-docs-preview.netlify.app
Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

colinrotherham commented 8 months ago

Looking good

GOV.UK Frontend still gets installed in the same place

On this repo we only use Node.js for:

  1. Building SassDoc via npm run build:sassdoc
  2. Linting JavaScript via npm run lint
  3. Checking links via npm run check-links