Commit 12901c1
committed
Add exports to package.json to satisfy nodejs --experimental-module users
Fixes #206
This ensures that consumers using --experimental-modules with node 12+
will import the esm version of this package.
This package's export must a package.json with "type": "json" (or module
files must have .mjs extension)...
This package's export must also use exports field in the package.json
because node doesn't support the "module" field as an alternative to
"main".
see https://nodejs.org/api/packages.html#conditional-exports1 parent cc4f9ae commit 12901c1
1 file changed
+5
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
20 | 20 | | |
21 | 21 | | |
22 | 22 | | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
23 | 27 | | |
24 | 28 | | |
25 | 29 | | |
| |||
28 | 32 | | |
29 | 33 | | |
30 | 34 | | |
31 | | - | |
| 35 | + | |
32 | 36 | | |
33 | 37 | | |
34 | 38 | | |
| |||
0 commit comments