node/test/fixtures/es-modules/json-modules-attributes.mjs
Chengzhong Wu cc856b3d5d
module: link module with a module request record
When a module is being statically linked with module requests, if two
module requests with a same specifier but different attributes are
resolved to two modules, the module requests should be linked to these
two modules.

PR-URL: https://github.com/nodejs/node/pull/58886
Refs: https://tc39.es/ecma262/#sec-HostLoadImportedModule
Refs: https://github.com/tc39/proposal-import-attributes?tab=readme-ov-file#how-would-this-proposal-work-with-caching
Reviewed-By: Guy Bedford <guybedford@gmail.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
2025-07-04 19:56:08 +00:00

6 lines
254 B
JavaScript

import * as secretJson from '../primitive-42.json' with { type: 'json' };
import * as secretModule from '../primitive-42.json';
import * as secretJson2 from '../primitive-42.json' with { type: 'json' };
export { secretModule, secretJson, secretJson2 };