Skip to content

Commit

Permalink
Add ".js" extension to auto-generated import files in babel-plugin-tr…
Browse files Browse the repository at this point in the history
…ansform-runtime #10548
  • Loading branch information
shimataro committed Oct 19, 2019
1 parent 7ec7cac commit 5099579
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/babel-plugin-transform-runtime/src/index.js
Expand Up @@ -254,7 +254,7 @@ export default declare((api, options, dirname) => {
if (cached) {
cached = t.cloneNode(cached);
} else {
cached = addDefault(file.path, source, {
cached = addDefault(file.path, `${source}.js`, {
importedInterop: "uncompiled",
nameHint,
blockHoist,
Expand All @@ -275,7 +275,7 @@ export default declare((api, options, dirname) => {
if (name === "regeneratorRuntime" && useRuntimeRegenerator) {
path.replaceWith(
this.addDefaultImport(
`${modulePath}/regenerator`,
`${modulePath}/regenerator/index`,
"regeneratorRuntime",
),
);
Expand Down

0 comments on commit 5099579

Please sign in to comment.