Skip to content

Commit f8016eb

Browse files
authoredOct 8, 2024··
chore: raise minimum node version to 20+ (#2707)
* chore: raise minimum node version to 20+ * fix: Intl RangeError exception * chore: update @types/node * chore: add changeset

File tree

16 files changed

+123
-42
lines changed

16 files changed

+123
-42
lines changed
 

‎.changeset/heavy-chairs-repeat.md

+13
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
---
2+
"@sumup-oss/stylelint-plugin-circuit-ui": major
3+
"@sumup-oss/eslint-plugin-circuit-ui": major
4+
"next-app": major
5+
"@sumup-oss/design-tokens": major
6+
"@sumup-oss/circuit-ui": major
7+
"@sumup-oss/cna-template": major
8+
"@sumup-oss/astro-template-circuit-ui": major
9+
"@sumup-oss/remix-template-circuit-ui": major
10+
"@sumup-oss/icons": major
11+
---
12+
13+
Raised the minimum Node.js version to 20+.

‎.github/workflows/chromatic.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -16,10 +16,10 @@ jobs:
1616
with:
1717
fetch-depth: 0
1818

19-
- name: Setup Node.js v18
19+
- name: Setup Node.js v20
2020
uses: actions/setup-node@v4
2121
with:
22-
node-version: 18.x
22+
node-version: 20.x
2323
cache: 'npm'
2424

2525
- name: Install dependencies

‎.github/workflows/ci.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ jobs:
77
runs-on: ubuntu-latest
88
strategy:
99
matrix:
10-
node: [18, 20]
10+
node: [20, 22]
1111
steps:
1212
- name: Checkout repository
1313
uses: actions/checkout@v4

‎.github/workflows/templates.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ jobs:
1111
strategy:
1212
# https://docs.github.com/en/actions/using-jobs/using-a-matrix-for-your-jobs
1313
matrix:
14-
node: [18, 20]
14+
node: [20, 22]
1515
template: [astro, nextjs, remix]
1616
include:
1717
- template: astro

‎.nvmrc

+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
lts/hydrogen
1+
lts/iron

‎CONTRIBUTING.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ We appreciate pull requests (PRs) for smaller changes and bug fixes. For larger
3232

3333
### Prerequisites
3434

35-
- [Node.js v18](https://nodejs.org/)
35+
- [Node.js v20](https://nodejs.org/)
3636

3737
### Installation
3838

‎package-lock.json

+94-26
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

‎package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@
6161
"@sumup-oss/foundry": "^8.2.0",
6262
"@sumup-oss/eslint-plugin-circuit-ui": "^4.0.0",
6363
"@sumup-oss/stylelint-plugin-circuit-ui": "^2.0.0",
64-
"@types/node": "^18.19.39",
64+
"@types/node": "^22.7.4",
6565
"@vitest/coverage-v8": "^2.0.5",
6666
"audit-ci": "^7.1.0",
6767
"chromatic": "^11.7.1",

‎packages/circuit-ui/components/PhoneNumberInput/PhoneNumberInputService.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ export function mapCountryCodeOptions(
4646
const displayName = new Intl.DisplayNames(locale, { type: 'region' });
4747
return countryCodeOptions
4848
.map(({ code, country }) => {
49-
const countryName = displayName.of(country);
49+
const countryName = country ? displayName.of(country) : country;
5050
return {
5151
label: countryName ? `${countryName} (${code})` : code,
5252
value: code,

‎packages/circuit-ui/package.json

+2-2
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@
7171
"@testing-library/react": "^16.0.1",
7272
"@testing-library/user-event": "^14.5.2",
7373
"@types/jest-axe": "^3.5.9",
74-
"@types/node": "^18.19.39",
74+
"@types/node": "^22.7.4",
7575
"@types/react": "^18.3.3",
7676
"@types/react-dates": "^21.8.6",
7777
"@types/react-dom": "^18.3.0",
@@ -102,6 +102,6 @@
102102
"react-dates": ">=21.8"
103103
},
104104
"engines": {
105-
"node": ">=18"
105+
"node": ">=20"
106106
}
107107
}

‎packages/design-tokens/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@
3636
"prop-types": "^15.8.1"
3737
},
3838
"devDependencies": {
39-
"@types/node": "^18.19.39",
39+
"@types/node": "^22.7.4",
4040
"@types/prop-types": "^15.7.12",
4141
"tsx": "^4.16.5",
4242
"typescript": "^5.5.4"

‎packages/icons/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,6 @@
4848
"react": ">=16.0.0 <19.0.0"
4949
},
5050
"engines": {
51-
"node": ">=18"
51+
"node": ">=20"
5252
}
5353
}

‎templates/nextjs/README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ A [create-next-app template](https://nextjs.org/docs/api-reference/create-next-a
1010

1111
## 💻 Prerequisites
1212

13-
- You should have **Node.js** installed at a version equal to or above **`v18.0.0`**.
13+
- You should have **Node.js** installed at a version equal to or above **`v20.0.0`**.
1414

1515
## ✨ Setting up a new Circuit UI + Next.js project
1616

‎templates/nextjs/template/.nvmrc

+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
lts/hydrogen
1+
lts/iron

‎templates/nextjs/template/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@
3131
"@testing-library/user-event": "^14.5.2",
3232
"@types/jest": "^29.5.12",
3333
"@types/jest-axe": "^3.5.9",
34-
"@types/node": "^18.19.39",
34+
"@types/node": "^22.7.4",
3535
"@types/react": "^18.3.3",
3636
"@types/react-dom": "^18.3.0",
3737
"eslint-config-next": "^14.2.5",

‎templates/remix/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,6 @@
3838
"typescript-plugin-css-modules": "^5.1.0"
3939
},
4040
"engines": {
41-
"node": ">=18"
41+
"node": ">=20"
4242
}
4343
}

0 commit comments

Comments
 (0)
Please sign in to comment.