Skip to content

Commit 57ef12e

Browse files
committed
Build: use --input-type=module in npm scripts
Ref jquerygh-5521
1 parent 53ad94f commit 57ef12e

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

package.json

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -45,13 +45,13 @@
4545
},
4646
"main": "dist/jquery.js",
4747
"scripts": {
48-
"authors:check": "node -e \"(async () => { const { checkAuthors } = await import('./build/release/authors.js'); checkAuthors() })()\"",
49-
"authors:update": "node -e \"(async () => { const { updateAuthors } = await import('./build/release/authors.js'); updateAuthors() })()\"",
48+
"authors:check": "node --input-type=module -e \"import { checkAuthors } from './build/release/authors.js'; checkAuthors()\"",
49+
"authors:update": "node --input-type=module -e \"import { updateAuthors } from './build/release/authors.js'; updateAuthors()\"",
5050
"babel:tests": "babel test/data/core/jquery-iterability-transpiled-es6.js --out-file test/data/core/jquery-iterability-transpiled.js",
5151
"build": "node ./build/command.js",
52-
"build:all": "node -e \"(async () => { const { buildDefaultFiles } = await import('./build/tasks/build.js'); buildDefaultFiles() })()\"",
52+
"build:all": "node --input-type=module -e \"import { buildDefaultFiles } from './build/tasks/build.js'; buildDefaultFiles()\"",
5353
"build:clean": "rimraf --glob dist/*.{js,map} --glob dist-module/*.{js,map}",
54-
"build:main": "node -e \"(async () => { const { build } = await import('./build/tasks/build.js'); build() })()\"",
54+
"build:main": "node --input-type=module -e \"import { build } from './build/tasks/build.js'; build()\"",
5555
"lint:dev": "eslint --cache .",
5656
"lint:json": "jsonlint --quiet package.json",
5757
"lint": "concurrently -r \"npm:lint:dev\" \"npm:lint:json\"",
@@ -64,7 +64,7 @@
6464
"release:clean": "rimraf tmp changelog.html contributors.html",
6565
"release:dist": "node build/release/dist.js",
6666
"release:verify": "node build/release/verify.js",
67-
"start": "node -e \"(async () => { const { buildDefaultFiles } = await import('./build/tasks/build.js'); buildDefaultFiles({ watch: true }) })()\"",
67+
"start": "node --input-type=module -e \"import { buildDefaultFiles } from './build/tasks/build.js'; buildDefaultFiles({ watch: true })\"",
6868
"test:bundlers": "npm run pretest && npm run build:all && node test/bundler_smoke_tests/run-jsdom-tests.js",
6969
"test:browser": "npm run pretest && npm run build:main && npm run test:unit -- -b chrome -b firefox -h",
7070
"test:browserless": "npm run pretest && npm run build:all && node test/bundler_smoke_tests/run-jsdom-tests.js && node build/tasks/node_smoke_tests.js && node build/tasks/promises_aplus_tests.js && npm run test:unit -- -b jsdom -m basic",

0 commit comments

Comments
 (0)