Skip to content

Commit f253040

Browse files
committed
Require Node.js 20
1 parent 6ccc5a1 commit f253040

File tree

4 files changed

+18
-23
lines changed

4 files changed

+18
-23
lines changed

.github/workflows/main.yml

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,12 +10,11 @@ jobs:
1010
fail-fast: false
1111
matrix:
1212
node-version:
13+
- 24
1314
- 20
14-
- 18
15-
- 16
1615
steps:
17-
- uses: actions/checkout@v4
18-
- uses: actions/setup-node@v4
16+
- uses: actions/checkout@v5
17+
- uses: actions/setup-node@v5
1918
with:
2019
node-version: ${{ matrix.node-version }}
2120
- run: npm install

index.d.ts

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -9,12 +9,10 @@ export type Input =
99
| Iterable<Buffer | string | NodeJS.TypedArray>
1010
| AsyncIterable<Buffer | string | NodeJS.TypedArray>;
1111

12-
/* eslint-disable @typescript-eslint/ban-types */
1312
export type ObjectInput =
14-
| object
15-
| Iterable<object>
16-
| AsyncIterable<object>;
17-
/* eslint-enable @typescript-eslint/ban-types */
13+
| Record<string, unknown>
14+
| Iterable<Record<string, unknown>>
15+
| AsyncIterable<Record<string, unknown>>;
1816

1917
declare const intoStream: {
2018
/**

index.test-d.ts

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -27,14 +27,10 @@ intoStream(new Uint8Array(Buffer.from('unicorn').buffer)).pipe(process.stdout);
2727
intoStream(Promise.resolve('unicorn')).pipe(process.stdout);
2828
intoStream(Promise.resolve(unicornArray)).pipe(process.stdout);
2929
intoStream(Promise.resolve(new Set(unicornArray))).pipe(process.stdout);
30-
intoStream(Promise.resolve(new Set([Buffer.from('unicorn')]))).pipe(
31-
process.stdout,
32-
);
30+
intoStream(Promise.resolve(new Set([Buffer.from('unicorn')]))).pipe(process.stdout);
3331
intoStream(Promise.resolve(Buffer.from('unicorn'))).pipe(process.stdout);
3432
intoStream(Promise.resolve(Buffer.from('unicorn').buffer)).pipe(process.stdout);
35-
intoStream(Promise.resolve(new Uint8Array(Buffer.from('unicorn').buffer))).pipe(
36-
process.stdout,
37-
);
33+
intoStream(Promise.resolve(new Uint8Array(Buffer.from('unicorn').buffer))).pipe(process.stdout);
3834

3935
intoStream(asyncGeneratorFrom(unicornArray)()).pipe(process.stdout);
4036
intoStream(asyncIterableFrom(unicornArray)).pipe(process.stdout);

package.json

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -11,11 +11,13 @@
1111
"url": "https://sindresorhus.com"
1212
},
1313
"type": "module",
14-
"exports": "./index.js",
15-
"types": "./index.d.ts",
14+
"exports": {
15+
"types": "./index.d.ts",
16+
"default": "./index.js"
17+
},
1618
"sideEffects": false,
1719
"engines": {
18-
"node": ">=16"
20+
"node": ">=20"
1921
},
2022
"scripts": {
2123
"test": "xo && ava && tsd"
@@ -46,10 +48,10 @@
4648
"value"
4749
],
4850
"devDependencies": {
49-
"ava": "^5.3.0",
50-
"get-stream": "^6.0.1",
51-
"p-event": "^5.0.1",
52-
"tsd": "^0.28.1",
53-
"xo": "^0.54.2"
51+
"ava": "^6.4.1",
52+
"get-stream": "^9.0.1",
53+
"p-event": "^6.0.1",
54+
"tsd": "^0.33.0",
55+
"xo": "^1.2.2"
5456
}
5557
}

0 commit comments

Comments
 (0)