From 99a8156a292e0dfcc4e26a7cc4582745125750f6 Mon Sep 17 00:00:00 2001 From: Jon Koops Date: Tue, 30 Jan 2024 19:21:01 +0100 Subject: [PATCH] Drop support for end-of-life Node.js versions --- .github/workflows/main.yml | 2 +- README.md | 4 ++++ package.json | 2 +- 3 files changed, 6 insertions(+), 2 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index c99bec7..8f8d0b3 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -9,7 +9,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - node: [14, 16, 18, 20] + node: [18, 20] steps: - name: Check out repository uses: actions/checkout@v4 diff --git a/README.md b/README.md index 84aa67a..405718f 100644 --- a/README.md +++ b/README.md @@ -31,3 +31,7 @@ console.log(emailUrl); ## A note on error handling and reporting The RFC states that errors in the templates could optionally be handled and reported to the user. This implementation takes a slightly different approach in that it tries to do a best effort template expansion and leaves erroneous expressions in the returned URI instead of throwing errors. So for example, the incorrect expression `{unclosed` will return `{unclosed` as output. The leaves incorrect URLs to be handled by your URL library of choice. + +## Supported Node.js versions + +The same versions that are [actively supported by Node.js](https://github.com/nodejs/release#release-schedule) are also supported by `url-template`, older versions of Node.js might be compatible as well, but are not actively tested against. diff --git a/package.json b/package.json index 98acd10..38eb5a1 100644 --- a/package.json +++ b/package.json @@ -27,7 +27,7 @@ "types": "./lib/url-template.d.ts", "sideEffects": false, "engines": { - "node": "^12.20.0 || ^14.13.1 || >=16.0.0" + "node": ">=18" }, "scripts": { "test": "node --experimental-json-modules node_modules/mocha/bin/mocha --reporter spec"