node-version-alias
Advanced tools
Comparing version 4.0.0 to 4.1.0
@@ -9,2 +9,5 @@ import type { Options as AllNodeVersionsOptions } from 'all-node-versions' | ||
// @ts-error @typescript-eslint/no-duplicate-type-constituents | ||
type UpstreamOptions = AllNodeVersionsOptions & NormalizeNodeVersionOptions | ||
export interface Options { | ||
@@ -20,6 +23,10 @@ /** | ||
*/ | ||
mirror?: AllNodeVersionsOptions['mirror'] & | ||
NormalizeNodeVersionOptions['mirror'] | ||
mirror?: UpstreamOptions['mirror'] | ||
/** | ||
* Cancels when the signal is aborted. | ||
*/ | ||
signal?: UpstreamOptions['signal'] | ||
/** | ||
* The list of available Node.js versions is cached for one hour by default. | ||
@@ -32,3 +39,3 @@ * If the `fetch` option is: | ||
*/ | ||
fetch?: AllNodeVersionsOptions['fetch'] & NormalizeNodeVersionOptions['fetch'] | ||
fetch?: UpstreamOptions['fetch'] | ||
} | ||
@@ -88,2 +95,4 @@ | ||
* fetch: true, | ||
* // Cancels when the signal is aborted | ||
* signal: new AbortController().signal, | ||
* }) | ||
@@ -90,0 +99,0 @@ * ``` |
@@ -9,6 +9,6 @@ import isPlainObj from"is-plain-obj"; | ||
const{fetch:fetchOpt,mirror}=opts; | ||
const normalizeOpts={fetch:fetchOpt,mirror}; | ||
const allNodeOpts={fetch:fetchOpt,mirror}; | ||
const{fetch:fetchOpt,mirror,signal}=opts; | ||
const normalizeOpts={fetch:fetchOpt,mirror,signal}; | ||
const allNodeOpts={fetch:fetchOpt,mirror,signal}; | ||
return{normalizeOpts,allNodeOpts} | ||
}; |
{ | ||
"name": "node-version-alias", | ||
"version": "4.0.0", | ||
"version": "4.1.0", | ||
"type": "module", | ||
@@ -54,13 +54,13 @@ "exports": { | ||
"dependencies": { | ||
"all-node-versions": "^12.0.0", | ||
"all-node-versions": "^12.1.0", | ||
"filter-obj": "^5.1.0", | ||
"is-plain-obj": "^4.1.0", | ||
"normalize-node-version": "^13.0.0", | ||
"normalize-node-version": "^13.1.0", | ||
"path-exists": "^5.0.0", | ||
"semver": "^7.5.0" | ||
"semver": "^7.5.4" | ||
}, | ||
"devDependencies": { | ||
"@ehmicky/dev-tasks": "^2.0.80", | ||
"got": "^12.6.0", | ||
"test-each": "^5.7.1" | ||
"@ehmicky/dev-tasks": "^2.0.88", | ||
"got": "^13.0.0", | ||
"test-each": "^6.0.1" | ||
}, | ||
@@ -67,0 +67,0 @@ "engines": { |
@@ -63,2 +63,4 @@ [![Node](https://img.shields.io/badge/-Node.js-808080?logo=node.js&colorA=404040&logoColor=66cc33)](https://www.npmjs.com/package/node-version-alias) | ||
fetch: true, | ||
// Cancels when the signal is aborted | ||
signal: new AbortController().signal, | ||
}) | ||
@@ -115,2 +117,9 @@ ``` | ||
#### signal | ||
_Type_: | ||
[`AbortSignal`](https://developer.mozilla.org/en-US/docs/Web/API/AbortSignal) | ||
Cancels when the signal is aborted. | ||
# CLI | ||
@@ -117,0 +126,0 @@ |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
29016
216
199
Updatedall-node-versions@^12.1.0
Updatedsemver@^7.5.4