Implement importInterop: "node" option for module transforms (#12838)

This commit is contained in:
Nicolò Ribaudo
2021-04-28 18:22:47 +02:00
committed by GitHub
parent 22b0eb038f
commit be03be1bc3
101 changed files with 834 additions and 32 deletions

View File

@@ -38,7 +38,13 @@ function injectWrapper(path, wrapper) {
export default declare((api, options) => {
api.assertVersion(7);
const { allowTopLevelThis, strict, strictMode, noInterop } = options;
const {
allowTopLevelThis,
strict,
strictMode,
importInterop,
noInterop,
} = options;
const constantReexports =
api.assumption("constantReexports") ?? options.loose;
@@ -114,6 +120,7 @@ export default declare((api, options) => {
strict,
strictMode,
allowTopLevelThis,
importInterop,
noInterop,
},
);