diff --git a/packages/webchannel-wrapper/gulpfile.js b/packages/webchannel-wrapper/gulpfile.js index de51bc0ded1..8148bb036bb 100644 --- a/packages/webchannel-wrapper/gulpfile.js +++ b/packages/webchannel-wrapper/gulpfile.js @@ -120,7 +120,7 @@ function createRollupTask({ }; const outputOptions = { - file: `dist/index${outputExtension ? '.' : ''}${outputExtension}.js`, + file: `dist/index${outputExtension ? '.' : ''}${outputExtension}.mjs`, format, sourcemap: true, // Prevents warning when compiling CJS that there are named and default exports together. diff --git a/packages/webchannel-wrapper/package.json b/packages/webchannel-wrapper/package.json index 35217bc539f..3c23acef835 100644 --- a/packages/webchannel-wrapper/package.json +++ b/packages/webchannel-wrapper/package.json @@ -10,8 +10,8 @@ ".": { "types": "./src/index.d.ts", "require": "./dist/index.js", - "esm5": "./dist/index.esm.js", - "default": "./dist/index.esm2017.js" + "esm5": "./dist/index.esm.mjs", + "default": "./dist/index.esm2017.mjs" }, "./package.json": "./package.json" },