Skip to content

Commit 0954403

Browse files
ZakrepaShebillyvg
authored andcommitted
fix(module): keep version for node ESM package (#13922)
Module federation needs package version for comparison fixes #12433
1 parent 0248545 commit 0954403

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

dev-packages/rollup-utils/plugins/make-esm-plugin.mjs

+3
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,12 @@ export function makePackageNodeEsm() {
1515

1616
const packageJSON = JSON.parse(fs.readFileSync(packageJSONPath, 'utf-8'));
1717
const sideEffects = packageJSON.sideEffects;
18+
// For module federation we need to keep the version of the package
19+
const version = packageJSON.version;
1820

1921
const newPackageJSON = {
2022
type: 'module',
23+
version,
2124
sideEffects,
2225
};
2326

0 commit comments

Comments
 (0)