Allow defining the moduleIds-related option in the transform p… (#11194)
* Update "moduleIds" tests * Allow defining the moduleIds related options in the transform plugins - moduleIds - moduleId - getModuleId - moduleRoot * Sort deps
This commit is contained in:
@@ -7,6 +7,7 @@ import {
|
||||
buildNamespaceInitStatements,
|
||||
ensureStatementsHoisted,
|
||||
wrapInterop,
|
||||
getModuleName,
|
||||
} from "@babel/helper-module-transforms";
|
||||
import { template, types as t } from "@babel/core";
|
||||
import { getImportSource } from "babel-plugin-dynamic-import-node/utils";
|
||||
@@ -96,7 +97,7 @@ export default declare((api, options) => {
|
||||
importNames.push(requireId);
|
||||
}
|
||||
|
||||
let moduleName = this.getModuleName();
|
||||
let moduleName = getModuleName(this.file.opts, options);
|
||||
if (moduleName) moduleName = t.stringLiteral(moduleName);
|
||||
|
||||
const { meta, headers } = rewriteModuleStatementsAndPrepareHeader(
|
||||
|
||||
Reference in New Issue
Block a user