node/test/fixtures/es-modules
Antoine du Hamel d1ef6aa2db
esm: use import attributes instead of import assertions
The old import assertions proposal has been
renamed to "import attributes" with the follwing major changes:

1. The keyword is now `with` instead of `assert`.
2. Unknown assertions cause an error rather than being ignored,

This commit updates the documentation to encourage folks to use the new
syntax, and add aliases for module customization hooks.

PR-URL: https://github.com/nodejs/node/pull/50140
Fixes: https://github.com/nodejs/node/issues/50134
Refs: 159c82c5e6
Reviewed-By: Geoffrey Booth <webadmin@geoffreybooth.com>
Reviewed-By: Jacob Smith <jacob@frende.me>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
2023-10-14 03:52:38 +00:00
..
deprecated-folders-ignore
json-cache
legacy-main-resolver src,lib: reducing C++ calls of esm legacy main resolve 2023-07-03 18:42:47 +00:00
module-counter-by-type
package-cjs-named-error
package-type-commonjs
package-type-module esm: unflag extensionless javascript and wasm in module scope 2023-10-03 12:31:21 +08:00
package-without-pjson
package-without-type esm: bypass CommonJS loader under --default-type 2023-10-05 17:57:32 +00:00
pjson-invalid
pjson-main
pkgimports module: fix segment deprecation for imports field 2022-10-13 07:31:31 -07:00
self-deprecated-folders
tla
builtin-imports-case.mjs
cjs-esm-esm.js
cjs-esm.js
cjs-exports-invalid.mjs
cjs-exports.mjs
cjs-file.cjs
cjs.js
conditional-exports.js
conditional-exports.mjs
dep1.js
dep2.js
es-note-error-1.cjs
es-note-error-1.mjs
es-note-error-2.cjs
es-note-error-2.mjs
es-note-error-3.cjs
es-note-error-3.mjs
es-note-error-4.cjs
es-note-error-4.mjs
es-note-promiserej-import-2.cjs
es-note-unexpected-export-1.cjs
es-note-unexpected-export-2.cjs
es-note-unexpected-import-1.cjs
es-note-unexpected-import-3.cjs
es-note-unexpected-import-4.cjs
es-note-unexpected-import-5.cjs
esm-snapshot-mutator.js
esm-snapshot.js
esm-top-level-await.mjs esm: add --import flag 2022-07-31 04:08:02 +01:00
export-name-code-injection.wasm module: fix code injection through export names 2023-10-13 18:03:52 -03:00
export-name-code-injection.wat module: fix code injection through export names 2023-10-13 18:03:52 -03:00
export-name-syntax-error.wasm module: fix code injection through export names 2023-10-13 18:03:52 -03:00
export-name-syntax-error.wat module: fix code injection through export names 2023-10-13 18:03:52 -03:00
exports-cases.js
exports-cases2.js
exports-cases3.js
file.ext
file.unknown
import-invalid-ext.mjs
import-invalid-pjson.mjs
import-json-named-export.mjs esm: use import attributes instead of import assertions 2023-10-14 03:52:38 +00:00
import-name.wasm module: fix code injection through export names 2023-10-13 18:03:52 -03:00
import-name.wat module: fix code injection through export names 2023-10-13 18:03:52 -03:00
import-process-exit.mjs
import-resolve-exports.mjs esm: move hook execution to separate thread 2023-04-13 09:35:17 +02:00
imports-loose.mjs esm: --experimental-default-type flag to flip module defaults 2023-09-29 06:18:44 +00:00
imports-noext.mjs esm: --experimental-default-type flag to flip module defaults 2023-09-29 06:18:44 +00:00
invalid-cjs.js
invalid-posix-host.mjs esm: identify parent importing a url with invalid host 2023-09-23 05:41:26 +00:00
json-modules.mjs esm: use import attributes instead of import assertions 2023-10-14 03:52:38 +00:00
loop.mjs
loose.js esm: --experimental-default-type flag to flip module defaults 2023-09-29 06:18:44 +00:00
message.mjs
mjs-file.mjs
noext
noext-esm esm: --experimental-default-type flag to flip module defaults 2023-09-29 06:18:44 +00:00
noext-wasm esm: --experimental-default-type flag to flip module defaults 2023-09-29 06:18:44 +00:00
pattern-trailing-slash.mjs
print-3.mjs esm: add --import flag 2022-07-31 04:08:02 +01:00
process-exit.mjs
runmain.mjs esm: move hook execution to separate thread 2023-04-13 09:35:17 +02:00
simple.wasm
simple.wat
stateful.mjs
symlink.mjs
test-esm-comma,.mjs
test-esm-double-encoding-native%20.mjs
test-esm-ok.mjs
wasm-dep.mjs
wasm-modules.mjs