Skip to content

Commit 291aeda

Browse files
authored
fix(exports): node 13.0-13.6 require a string fallback (#333)
package.json’s "engines" field claims yargs-parser supports node >= 10; node v13.0-v13.6 are included in this semver range. This change is required to be able to require() from yargs-parser successfully in these versions. See yargs/yargs#1776
1 parent 94220bf commit 291aeda

File tree

1 file changed

+7
-4
lines changed

1 file changed

+7
-4
lines changed

package.json

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,13 @@
33
"version": "20.2.1",
44
"description": "the mighty option parser used by yargs",
55
"main": "build/index.cjs",
6-
"exports": {
7-
"import": "./build/lib/index.js",
8-
"require": "./build/index.cjs"
9-
},
6+
"exports": [
7+
{
8+
"import": "./build/lib/index.js",
9+
"require": "./build/index.cjs"
10+
},
11+
"./build/index.cjs"
12+
],
1013
"type": "module",
1114
"module": "./build/lib/index.js",
1215
"scripts": {

0 commit comments

Comments
 (0)