@emulsify/cli 2.1.0 → 2.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +43 -264
- package/dist/handlers/init.js +13 -5
- package/dist/handlers/systemInstall.js +77 -4
- package/dist/index.js +99 -21
- package/dist/node_modules/.package-lock.json +11 -11
- package/dist/node_modules/@types/node/README.md +1 -1
- package/dist/node_modules/@types/node/assert/strict.d.ts +10 -1
- package/dist/node_modules/@types/node/assert.d.ts +144 -17
- package/dist/node_modules/@types/node/async_hooks.d.ts +9 -9
- package/dist/node_modules/@types/node/buffer.d.ts +0 -5
- package/dist/node_modules/@types/node/child_process.d.ts +17 -21
- package/dist/node_modules/@types/node/cluster.d.ts +13 -13
- package/dist/node_modules/@types/node/console.d.ts +1 -1
- package/dist/node_modules/@types/node/crypto.d.ts +454 -571
- package/dist/node_modules/@types/node/diagnostics_channel.d.ts +20 -9
- package/dist/node_modules/@types/node/dns.d.ts +14 -14
- package/dist/node_modules/@types/node/events.d.ts +3 -3
- package/dist/node_modules/@types/node/fs/promises.d.ts +4 -4
- package/dist/node_modules/@types/node/fs.d.ts +3 -12
- package/dist/node_modules/@types/node/globals.d.ts +4 -4
- package/dist/node_modules/@types/node/http.d.ts +5 -5
- package/dist/node_modules/@types/node/http2.d.ts +1 -1
- package/dist/node_modules/@types/node/index.d.ts +0 -3
- package/dist/node_modules/@types/node/inspector.d.ts +1 -1
- package/dist/node_modules/@types/node/module.d.ts +16 -45
- package/dist/node_modules/@types/node/net.d.ts +1 -1
- package/dist/node_modules/@types/node/os.d.ts +2 -2
- package/dist/node_modules/@types/node/package.json +4 -4
- package/dist/node_modules/@types/node/perf_hooks.d.ts +1 -9
- package/dist/node_modules/@types/node/process.d.ts +11 -11
- package/dist/node_modules/@types/node/readline.d.ts +12 -11
- package/dist/node_modules/@types/node/repl.d.ts +10 -10
- package/dist/node_modules/@types/node/sqlite.d.ts +1 -1
- package/dist/node_modules/@types/node/stream/promises.d.ts +2 -2
- package/dist/node_modules/@types/node/stream/web.d.ts +1 -1
- package/dist/node_modules/@types/node/stream.d.ts +5 -5
- package/dist/node_modules/@types/node/test/reporters.d.ts +1 -1
- package/dist/node_modules/@types/node/test.d.ts +8 -8
- package/dist/node_modules/@types/node/tls.d.ts +1 -1
- package/dist/node_modules/@types/node/ts5.6/index.d.ts +1 -4
- package/dist/node_modules/@types/node/ts5.7/index.d.ts +0 -3
- package/dist/node_modules/@types/node/url.d.ts +3 -3
- package/dist/node_modules/@types/node/util/types.d.ts +1 -1
- package/dist/node_modules/@types/node/util.d.ts +3 -20
- package/dist/node_modules/@types/node/v8.d.ts +1 -1
- package/dist/node_modules/@types/node/vm.d.ts +9 -9
- package/dist/node_modules/@types/node/web-globals/domexception.d.ts +15 -0
- package/dist/node_modules/@types/node/worker_threads.d.ts +2 -5
- package/dist/node_modules/@types/node/zlib.d.ts +3 -3
- package/dist/node_modules/chardet/README.md +15 -1
- package/dist/node_modules/chardet/lib/encoding/sbcs.d.ts +19 -0
- package/dist/node_modules/chardet/lib/encoding/sbcs.js +172 -1
- package/dist/node_modules/chardet/lib/encoding/sbcs.js.map +1 -1
- package/dist/node_modules/chardet/lib/index.js +3 -0
- package/dist/node_modules/chardet/lib/index.js.map +1 -1
- package/dist/node_modules/chardet/lib/match.d.ts +1 -1
- package/dist/node_modules/chardet/lib/match.js.map +1 -1
- package/dist/node_modules/chardet/package.json +14 -10
- package/dist/node_modules/undici-types/agent.d.ts +0 -2
- package/dist/node_modules/undici-types/client.d.ts +25 -19
- package/dist/node_modules/undici-types/dispatcher.d.ts +7 -33
- package/dist/node_modules/undici-types/dispatcher1-wrapper.d.ts +7 -0
- package/dist/node_modules/undici-types/fetch.d.ts +24 -4
- package/dist/node_modules/undici-types/h2c-client.d.ts +6 -6
- package/dist/node_modules/undici-types/handlers.d.ts +1 -2
- package/dist/node_modules/undici-types/header.d.ts +5 -0
- package/dist/node_modules/undici-types/index.d.ts +3 -1
- package/dist/node_modules/undici-types/interceptors.d.ts +1 -1
- package/dist/node_modules/undici-types/package.json +1 -1
- package/dist/node_modules/undici-types/pool.d.ts +0 -2
- package/dist/node_modules/undici-types/proxy-agent.d.ts +2 -2
- package/dist/node_modules/undici-types/round-robin-pool.d.ts +0 -2
- package/dist/node_modules/undici-types/snapshot-agent.d.ts +4 -0
- package/dist/node_modules/undici-types/socks5-proxy-agent.d.ts +2 -2
- package/dist/node_modules/undici-types/webidl.d.ts +0 -1
- package/dist/package-lock.json +37 -37
- package/dist/package.json +2 -2
- package/dist/util/fs/executeScript.js +5 -4
- package/dist/util/platform/getInitSuccessMessageForPlatform.js +30 -25
- package/package.json +2 -2
- package/dist/node_modules/@types/node/compatibility/iterators.d.ts +0 -21
package/dist/package-lock.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@emulsify/cli",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.2.0",
|
|
4
4
|
"lockfileVersion": 3,
|
|
5
5
|
"requires": true,
|
|
6
6
|
"packages": {
|
|
7
7
|
"": {
|
|
8
8
|
"name": "@emulsify/cli",
|
|
9
|
-
"version": "2.
|
|
9
|
+
"version": "2.2.0",
|
|
10
10
|
"license": "GPL-2.0",
|
|
11
11
|
"dependencies": {
|
|
12
12
|
"@inquirer/prompts": "^8.5.2",
|
|
@@ -32,7 +32,7 @@
|
|
|
32
32
|
"@semantic-release/release-notes-generator": "^14.1.1",
|
|
33
33
|
"@types/fs-extra": "^11.0.4",
|
|
34
34
|
"@types/jest": "^30.0.0",
|
|
35
|
-
"@types/node": "^
|
|
35
|
+
"@types/node": "^26.0.0",
|
|
36
36
|
"@types/progress": "^2.0.7",
|
|
37
37
|
"husky": "^9.1.7",
|
|
38
38
|
"jest": "^30.4.2",
|
|
@@ -82,9 +82,9 @@
|
|
|
82
82
|
}
|
|
83
83
|
},
|
|
84
84
|
"node_modules/@actions/http-client/node_modules/undici": {
|
|
85
|
-
"version": "6.
|
|
86
|
-
"resolved": "https://registry.npmjs.org/undici/-/undici-6.
|
|
87
|
-
"integrity": "sha512-
|
|
85
|
+
"version": "6.27.0",
|
|
86
|
+
"resolved": "https://registry.npmjs.org/undici/-/undici-6.27.0.tgz",
|
|
87
|
+
"integrity": "sha512-YmfV3YnEDzXRC5lZ2jWtWWHKGUm1zIt8AhesR1tens+HTNv+YZlN/dp6G727LOvMJ8xjP9Be7Y2Sdr96LDm+pg==",
|
|
88
88
|
"dev": true,
|
|
89
89
|
"license": "MIT",
|
|
90
90
|
"engines": {
|
|
@@ -2677,13 +2677,13 @@
|
|
|
2677
2677
|
"license": "MIT"
|
|
2678
2678
|
},
|
|
2679
2679
|
"node_modules/@types/node": {
|
|
2680
|
-
"version": "
|
|
2681
|
-
"resolved": "https://registry.npmjs.org/@types/node/-/node-
|
|
2682
|
-
"integrity": "sha512-
|
|
2680
|
+
"version": "26.0.0",
|
|
2681
|
+
"resolved": "https://registry.npmjs.org/@types/node/-/node-26.0.0.tgz",
|
|
2682
|
+
"integrity": "sha512-vf2YFi1iY9lHGwNJMs01biZFbKJkrZR1T6/MlzjhJLPdntOHLhTrDSnSVcdtvjihi4VQNlrFRIxLsDBlQpAipA==",
|
|
2683
2683
|
"devOptional": true,
|
|
2684
2684
|
"license": "MIT",
|
|
2685
2685
|
"dependencies": {
|
|
2686
|
-
"undici-types": "
|
|
2686
|
+
"undici-types": "~8.3.0"
|
|
2687
2687
|
}
|
|
2688
2688
|
},
|
|
2689
2689
|
"node_modules/@types/normalize-package-data": {
|
|
@@ -3478,9 +3478,9 @@
|
|
|
3478
3478
|
"license": "MIT"
|
|
3479
3479
|
},
|
|
3480
3480
|
"node_modules/baseline-browser-mapping": {
|
|
3481
|
-
"version": "2.10.
|
|
3482
|
-
"resolved": "https://registry.npmjs.org/baseline-browser-mapping/-/baseline-browser-mapping-2.10.
|
|
3483
|
-
"integrity": "sha512-
|
|
3481
|
+
"version": "2.10.38",
|
|
3482
|
+
"resolved": "https://registry.npmjs.org/baseline-browser-mapping/-/baseline-browser-mapping-2.10.38.tgz",
|
|
3483
|
+
"integrity": "sha512-31/02mVB4yuQU6adKk5SlY6m+mxDwUq5KZkyYgnLrrKl7TEm1+3PyDtDBz2kOv/wxZz41GHsvV1A/u6RmiyBvw==",
|
|
3484
3484
|
"dev": true,
|
|
3485
3485
|
"license": "Apache-2.0",
|
|
3486
3486
|
"bin": {
|
|
@@ -3692,9 +3692,9 @@
|
|
|
3692
3692
|
}
|
|
3693
3693
|
},
|
|
3694
3694
|
"node_modules/chardet": {
|
|
3695
|
-
"version": "2.
|
|
3696
|
-
"resolved": "https://registry.npmjs.org/chardet/-/chardet-2.
|
|
3697
|
-
"integrity": "sha512-
|
|
3695
|
+
"version": "2.2.0",
|
|
3696
|
+
"resolved": "https://registry.npmjs.org/chardet/-/chardet-2.2.0.tgz",
|
|
3697
|
+
"integrity": "sha512-rddelWYNPRrXq6PtNEN2S3f6t9ILzvqaN5pVgi4kqt9jHQaXIial9PznB5iSPVlQSLNaaH22ItWz3EJtQ10+OA==",
|
|
3698
3698
|
"license": "MIT"
|
|
3699
3699
|
},
|
|
3700
3700
|
"node_modules/chokidar": {
|
|
@@ -3930,9 +3930,9 @@
|
|
|
3930
3930
|
}
|
|
3931
3931
|
},
|
|
3932
3932
|
"node_modules/cli-highlight/node_modules/yargs": {
|
|
3933
|
-
"version": "16.2.
|
|
3934
|
-
"resolved": "https://registry.npmjs.org/yargs/-/yargs-16.2.
|
|
3935
|
-
"integrity": "sha512-
|
|
3933
|
+
"version": "16.2.2",
|
|
3934
|
+
"resolved": "https://registry.npmjs.org/yargs/-/yargs-16.2.2.tgz",
|
|
3935
|
+
"integrity": "sha512-Nt9ZJjXTv5R8MHbqby/wXQ6Gi0Bb3TcYZkR1bzuL4yB2OxWPkXknz513gEF0GoA6tn00UpbPvERW8rzCuWCA6w==",
|
|
3936
3936
|
"dev": true,
|
|
3937
3937
|
"license": "MIT",
|
|
3938
3938
|
"dependencies": {
|
|
@@ -4511,9 +4511,9 @@
|
|
|
4511
4511
|
"license": "MIT"
|
|
4512
4512
|
},
|
|
4513
4513
|
"node_modules/electron-to-chromium": {
|
|
4514
|
-
"version": "1.5.
|
|
4515
|
-
"resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.5.
|
|
4516
|
-
"integrity": "sha512-
|
|
4514
|
+
"version": "1.5.376",
|
|
4515
|
+
"resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.5.376.tgz",
|
|
4516
|
+
"integrity": "sha512-cUVA7/RvbFTEuw/i3obUwDTRIXojaxkResf+ibByPFxjc6XK3VNtcQXV0NSbAlJ0FMjcJGgftVVB4Qo184EXvA==",
|
|
4517
4517
|
"dev": true,
|
|
4518
4518
|
"license": "ISC"
|
|
4519
4519
|
},
|
|
@@ -6121,9 +6121,9 @@
|
|
|
6121
6121
|
}
|
|
6122
6122
|
},
|
|
6123
6123
|
"node_modules/jest-cli/node_modules/yargs": {
|
|
6124
|
-
"version": "17.7.
|
|
6125
|
-
"resolved": "https://registry.npmjs.org/yargs/-/yargs-17.7.
|
|
6126
|
-
"integrity": "sha512-
|
|
6124
|
+
"version": "17.7.3",
|
|
6125
|
+
"resolved": "https://registry.npmjs.org/yargs/-/yargs-17.7.3.tgz",
|
|
6126
|
+
"integrity": "sha512-GZtjxm/J/4TSxuL3FNYjCmLktBTnIw/rVmKSIyKeYAZpmJB2ig9VauCC5xsa82GNKVKDAqpOn3KVzNt0zmrU0g==",
|
|
6127
6127
|
"dev": true,
|
|
6128
6128
|
"license": "MIT",
|
|
6129
6129
|
"dependencies": {
|
|
@@ -7744,9 +7744,9 @@
|
|
|
7744
7744
|
"license": "MIT"
|
|
7745
7745
|
},
|
|
7746
7746
|
"node_modules/node-releases": {
|
|
7747
|
-
"version": "2.0.
|
|
7748
|
-
"resolved": "https://registry.npmjs.org/node-releases/-/node-releases-2.0.
|
|
7749
|
-
"integrity": "sha512-
|
|
7747
|
+
"version": "2.0.48",
|
|
7748
|
+
"resolved": "https://registry.npmjs.org/node-releases/-/node-releases-2.0.48.tgz",
|
|
7749
|
+
"integrity": "sha512-1uz8041X6LoI6ZSdZacM9lVY28vuzDlSKitnpbSNK0RfKoIJkX29NBPVEFXhnuSuEOA9Ww0xnPJ+ILWbGAv8DA==",
|
|
7750
7750
|
"dev": true,
|
|
7751
7751
|
"license": "MIT",
|
|
7752
7752
|
"engines": {
|
|
@@ -9093,9 +9093,9 @@
|
|
|
9093
9093
|
}
|
|
9094
9094
|
},
|
|
9095
9095
|
"node_modules/semver": {
|
|
9096
|
-
"version": "7.8.
|
|
9097
|
-
"resolved": "https://registry.npmjs.org/semver/-/semver-7.8.
|
|
9098
|
-
"integrity": "sha512-
|
|
9096
|
+
"version": "7.8.5",
|
|
9097
|
+
"resolved": "https://registry.npmjs.org/semver/-/semver-7.8.5.tgz",
|
|
9098
|
+
"integrity": "sha512-Y7/KDsb8LjooZpwaqGyulO6DQlksgCncchHGk+sZIY4SBvUocMBEFH5Ur1fI4dV+Jvl0w6cjvucaIi40puRioA==",
|
|
9099
9099
|
"dev": true,
|
|
9100
9100
|
"license": "ISC",
|
|
9101
9101
|
"bin": {
|
|
@@ -10148,9 +10148,9 @@
|
|
|
10148
10148
|
"license": "MIT"
|
|
10149
10149
|
},
|
|
10150
10150
|
"node_modules/undici": {
|
|
10151
|
-
"version": "7.
|
|
10152
|
-
"resolved": "https://registry.npmjs.org/undici/-/undici-7.
|
|
10153
|
-
"integrity": "sha512-
|
|
10151
|
+
"version": "7.28.0",
|
|
10152
|
+
"resolved": "https://registry.npmjs.org/undici/-/undici-7.28.0.tgz",
|
|
10153
|
+
"integrity": "sha512-cRZYrTDwWznlnRiPjggAGxZXanty6M8RV1ff8Wm4LWXBp7/IG8v5DnOm74DtUBp9OONpK75YlPnIjQqX0dBDtA==",
|
|
10154
10154
|
"dev": true,
|
|
10155
10155
|
"license": "MIT",
|
|
10156
10156
|
"engines": {
|
|
@@ -10158,9 +10158,9 @@
|
|
|
10158
10158
|
}
|
|
10159
10159
|
},
|
|
10160
10160
|
"node_modules/undici-types": {
|
|
10161
|
-
"version": "
|
|
10162
|
-
"resolved": "https://registry.npmjs.org/undici-types/-/undici-types-
|
|
10163
|
-
"integrity": "sha512-
|
|
10161
|
+
"version": "8.3.0",
|
|
10162
|
+
"resolved": "https://registry.npmjs.org/undici-types/-/undici-types-8.3.0.tgz",
|
|
10163
|
+
"integrity": "sha512-j375ScV60dom+YkPFIfTLcOiPxkN/buHz5GobjLhixFuANaNs3C9l4GmrWqejgXWJ7BbJcFYpTEUkS1Ge8bpZQ==",
|
|
10164
10164
|
"devOptional": true,
|
|
10165
10165
|
"license": "MIT"
|
|
10166
10166
|
},
|
package/dist/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@emulsify/cli",
|
|
3
3
|
"productName": "Emulsify CLI",
|
|
4
|
-
"version": "2.
|
|
4
|
+
"version": "2.2.0",
|
|
5
5
|
"description": "Command line interface for Emulsify",
|
|
6
6
|
"repository": "git@github.com:emulsify-ds/emulsify-cli.git",
|
|
7
7
|
"author": "Patrick Coffey <patrickcoffey48@gmail.com>",
|
|
@@ -48,7 +48,7 @@
|
|
|
48
48
|
"@semantic-release/release-notes-generator": "^14.1.1",
|
|
49
49
|
"@types/fs-extra": "^11.0.4",
|
|
50
50
|
"@types/jest": "^30.0.0",
|
|
51
|
-
"@types/node": "^
|
|
51
|
+
"@types/node": "^26.0.0",
|
|
52
52
|
"@types/progress": "^2.0.7",
|
|
53
53
|
"husky": "^9.1.7",
|
|
54
54
|
"jest": "^30.4.2",
|
|
@@ -1,14 +1,15 @@
|
|
|
1
1
|
import { execFile } from 'child_process';
|
|
2
|
-
import { dirname } from 'path';
|
|
2
|
+
import { dirname, resolve as resolvePath } from 'path';
|
|
3
3
|
export default async function executeScript(scriptPath) {
|
|
4
|
+
const resolvedScriptPath = resolvePath(scriptPath);
|
|
4
5
|
return new Promise((resolve, reject) => {
|
|
5
|
-
execFile(process.execPath, [
|
|
6
|
-
cwd: dirname(
|
|
6
|
+
execFile(process.execPath, [resolvedScriptPath], {
|
|
7
|
+
cwd: dirname(resolvedScriptPath),
|
|
7
8
|
encoding: 'utf8',
|
|
8
9
|
}, (error, stdout, stderr) => {
|
|
9
10
|
if (error) {
|
|
10
11
|
const output = stderr.trim() || error.message;
|
|
11
|
-
return reject(new Error(`Unable to execute hook script "${
|
|
12
|
+
return reject(new Error(`Unable to execute hook script "${resolvedScriptPath}": ${output}`));
|
|
12
13
|
}
|
|
13
14
|
resolve(stdout || stderr || '');
|
|
14
15
|
});
|
|
@@ -1,31 +1,36 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
const DRUPAL_INTEGRATION_MESSAGE = [
|
|
2
|
+
'Detected a Drupal project.',
|
|
3
|
+
'',
|
|
4
|
+
'Install the required Drupal packages with Composer:',
|
|
5
|
+
' composer require drupal/emulsify drupal/emulsify_tools',
|
|
6
|
+
' drush en emulsify_tools -y',
|
|
7
|
+
'',
|
|
8
|
+
'The generated Drupal starter uses drupal/emulsify as its base theme and emulsify_tools for Drupal integration, so both packages must exist in the Drupal codebase.',
|
|
9
|
+
].join('\n');
|
|
10
|
+
const SYSTEM_SELECTION_MESSAGE = [
|
|
11
|
+
'Next, choose a component system:',
|
|
12
|
+
' emulsify system install',
|
|
13
|
+
].join('\n');
|
|
14
|
+
export default function getInitSuccessMessageForPlatform(platform, _directory, options = {}) {
|
|
15
|
+
if (platform === 'drupal') {
|
|
16
|
+
const messages = [];
|
|
17
|
+
if (options.includeDrupalInstallReminder) {
|
|
18
|
+
messages.push({
|
|
19
|
+
method: 'warn',
|
|
20
|
+
message: DRUPAL_INTEGRATION_MESSAGE,
|
|
21
|
+
});
|
|
22
|
+
}
|
|
23
|
+
messages.push({
|
|
24
|
+
method: 'info',
|
|
25
|
+
message: SYSTEM_SELECTION_MESSAGE,
|
|
26
|
+
});
|
|
27
|
+
return messages;
|
|
28
|
+
}
|
|
29
|
+
if (platform === 'none') {
|
|
4
30
|
return [
|
|
5
31
|
{
|
|
6
32
|
method: 'info',
|
|
7
|
-
message:
|
|
8
|
-
},
|
|
9
|
-
{
|
|
10
|
-
method: 'verbose',
|
|
11
|
-
message: `
|
|
12
|
-
- composer require drupal/components
|
|
13
|
-
- composer require drupal/emulsify_twig
|
|
14
|
-
- drush en components emulsify_twig -y
|
|
15
|
-
`,
|
|
16
|
-
},
|
|
17
|
-
{
|
|
18
|
-
method: 'info',
|
|
19
|
-
message: `Once the requirements have been installed, you will need to select a component system to use, as Emulsify does not come with components by default. To do this, navigate to your theme directory (${directory}), and choose a command below.`,
|
|
20
|
-
},
|
|
21
|
-
{
|
|
22
|
-
method: 'verbose',
|
|
23
|
-
message: `
|
|
24
|
-
${cyan('List systems')}: emulsify system list
|
|
25
|
-
${cyan('Install a system')}: emulsify system install "system-name"
|
|
26
|
-
${cyan('Install default system with default components')}: emulsify system install compound
|
|
27
|
-
${cyan('Install default system with all components')}: emulsify system install compound --all
|
|
28
|
-
`,
|
|
33
|
+
message: SYSTEM_SELECTION_MESSAGE,
|
|
29
34
|
},
|
|
30
35
|
];
|
|
31
36
|
}
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@emulsify/cli",
|
|
3
3
|
"productName": "Emulsify CLI",
|
|
4
|
-
"version": "2.
|
|
4
|
+
"version": "2.2.0",
|
|
5
5
|
"description": "Command line interface for Emulsify",
|
|
6
6
|
"repository": "git@github.com:emulsify-ds/emulsify-cli.git",
|
|
7
7
|
"author": "Patrick Coffey <patrickcoffey48@gmail.com>",
|
|
@@ -48,7 +48,7 @@
|
|
|
48
48
|
"@semantic-release/release-notes-generator": "^14.1.1",
|
|
49
49
|
"@types/fs-extra": "^11.0.4",
|
|
50
50
|
"@types/jest": "^30.0.0",
|
|
51
|
-
"@types/node": "^
|
|
51
|
+
"@types/node": "^26.0.0",
|
|
52
52
|
"@types/progress": "^2.0.7",
|
|
53
53
|
"husky": "^9.1.7",
|
|
54
54
|
"jest": "^30.4.2",
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
// Backwards-compatible iterator interfaces, augmented with iterator helper methods by lib.esnext.iterator in TypeScript 5.6.
|
|
2
|
-
// The IterableIterator interface does not contain these methods, which creates assignability issues in places where IteratorObjects
|
|
3
|
-
// are expected (eg. DOM-compatible APIs) if lib.esnext.iterator is loaded.
|
|
4
|
-
// Also ensures that iterators returned by the Node API, which inherit from Iterator.prototype, correctly expose the iterator helper methods
|
|
5
|
-
// if lib.esnext.iterator is loaded.
|
|
6
|
-
// TODO: remove once this package no longer supports TS 5.5, and replace NodeJS.BuiltinIteratorReturn with BuiltinIteratorReturn.
|
|
7
|
-
|
|
8
|
-
// Placeholders for TS <5.6
|
|
9
|
-
interface IteratorObject<T, TReturn, TNext> {}
|
|
10
|
-
interface AsyncIteratorObject<T, TReturn, TNext> {}
|
|
11
|
-
|
|
12
|
-
declare namespace NodeJS {
|
|
13
|
-
// Populate iterator methods for TS <5.6
|
|
14
|
-
interface Iterator<T, TReturn, TNext> extends globalThis.Iterator<T, TReturn, TNext> {}
|
|
15
|
-
interface AsyncIterator<T, TReturn, TNext> extends globalThis.AsyncIterator<T, TReturn, TNext> {}
|
|
16
|
-
|
|
17
|
-
// Polyfill for TS 5.6's instrinsic BuiltinIteratorReturn type, required for DOM-compatible iterators
|
|
18
|
-
type BuiltinIteratorReturn = ReturnType<any[][typeof Symbol.iterator]> extends
|
|
19
|
-
globalThis.Iterator<any, infer TReturn> ? TReturn
|
|
20
|
-
: any;
|
|
21
|
-
}
|