Files
Kmake/test/fixtures/es-module-loaders/missing-dynamic-instantiate-hook.mjs
2026-05-26 23:36:42 -07:00

18 lines
351 B
JavaScript

export function resolve(specifier, context, next) {
if (specifier === 'test') {
return {
url: 'file://'
};
}
return next(specifier);
}
export function getFormat(url, context, defaultGetFormat) {
if (url === 'file://') {
return {
format: 'dynamic'
}
}
return defaultGetFormat(url, context, defaultGetFormat);
}