Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: Resolve condition names #974

Merged
merged 14 commits into from
Jun 16, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 15 additions & 0 deletions packages/nextjs-mf/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,21 @@

This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver).

## [6.5.2-rc3.2](https://github.com/module-federation/nextjs-mf/compare/nextjs-mf-6.5.2-rc3.1...nextjs-mf-6.5.2-rc3.2) (2023-06-15)


### Bug Fixes

* dont force named chunkids on client ([d9c806a](https://github.com/module-federation/nextjs-mf/commit/d9c806ab6c330fd1ebb161a36e3491ff97d3eab0))
* eager share link to prevent stalled boots ([7cd7771](https://github.com/module-federation/nextjs-mf/commit/7cd7771b84f33ec91e44e60efc9ab7de6a847106))
* resolve conditional exports ([1520b01](https://github.com/module-federation/nextjs-mf/commit/1520b01ca77b5bc648625fc293bccde3419f4436))
* resolve conditional exports ([45bc380](https://github.com/module-federation/nextjs-mf/commit/45bc380cb8c5c041d7dcc1358f74212ceabe1c81))
* safety checks for getEagerSharedForChunkId ([a5c378b](https://github.com/module-federation/nextjs-mf/commit/a5c378b97e9728a5e12273fc6793e9d52e836e8f))
* safety checks for getEagerSharedForChunkId ([5b23677](https://github.com/module-federation/nextjs-mf/commit/5b23677109697d757dd5541ea4ad8975e06f4975))
* safety checks for getEagerSharedForChunkId ([1f4a238](https://github.com/module-federation/nextjs-mf/commit/1f4a238dbf20589b61f01850a56dad9a44e245b4))



## [6.5.2-rc3.1](https://github.com/module-federation/nextjs-mf/compare/nextjs-mf-6.5.2-rc3.0...nextjs-mf-6.5.2-rc3.1) (2023-06-09)


Expand Down
2 changes: 1 addition & 1 deletion packages/nextjs-mf/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@module-federation/nextjs-mf",
"version": "6.5.2-rc3.1",
"version": "6.5.2-rc3.2",
"license": "MIT",
"main": "src/index.js",
"types": "src/index.d.ts",
Expand Down
9 changes: 7 additions & 2 deletions packages/nextjs-mf/src/internal.ts
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ export const DEFAULT_SHARE_SCOPE: SharedObject = {
import: undefined,
},
'next/link': {
eager: false,
eager: true,
requiredVersion: false,
singleton: true,
import: undefined,
Expand Down Expand Up @@ -101,7 +101,12 @@ export const DEFAULT_SHARE_SCOPE_BROWSER: SharedObject = Object.entries(

acc[key] = { ...value, eager: undefined, import: undefined };

if (key === 'react' || key === 'react-dom' || key === 'next/router') {
if (
key === 'react' ||
key === 'react-dom' ||
key === 'next/router' ||
key === 'next/link'
) {
//@ts-ignore
acc[key].eager = true;
}
Expand Down
9 changes: 9 additions & 0 deletions packages/node/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,15 @@

This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver).

## [0.15.2-rc3.2](https://github.com/module-federation/nextjs-mf/compare/node-0.15.2-rc3.1...node-0.15.2-rc3.2) (2023-06-15)


### Bug Fixes

* safety checks for getEagerSharedForChunkId ([1f4a238](https://github.com/module-federation/nextjs-mf/commit/1f4a238dbf20589b61f01850a56dad9a44e245b4))



## [0.15.2-rc3.1](https://github.com/module-federation/nextjs-mf/compare/node-0.15.2-rc3.0...node-0.15.2-rc3.1) (2023-06-09)


Expand Down
2 changes: 1 addition & 1 deletion packages/node/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"public": true,
"name": "@module-federation/node",
"version": "0.15.2-rc3.1",
"version": "0.15.2-rc3.2",
"main": "src/index.js",
"exports": {
".": {
Expand Down
10 changes: 10 additions & 0 deletions packages/utilities/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,16 @@

This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver).

## [1.8.2-rc3.2](https://github.com/module-federation/nextjs-mf/compare/utils-1.8.2-rc3.1...utils-1.8.2-rc3.2) (2023-06-15)


### Bug Fixes

* eager share link to prevent stalled boots ([7cd7771](https://github.com/module-federation/nextjs-mf/commit/7cd7771b84f33ec91e44e60efc9ab7de6a847106))
* safety checks for getEagerSharedForChunkId ([1f4a238](https://github.com/module-federation/nextjs-mf/commit/1f4a238dbf20589b61f01850a56dad9a44e245b4))



## [1.8.2-rc3.1](https://github.com/module-federation/nextjs-mf/compare/utils-1.8.2-rc3.0...utils-1.8.2-rc3.1) (2023-06-09)


Expand Down
2 changes: 1 addition & 1 deletion packages/utilities/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@module-federation/utilities",
"version": "1.8.2-rc3.1",
"version": "1.8.2-rc3.2",
"main": "src/index.js",
"types": "src/index.d.ts",
"license": "MIT",
Expand Down
1 change: 1 addition & 0 deletions packages/utilities/src/utils/common.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ export const createDelegatedModule = (
}
queries.push(`${key}=${value}`);
}
if (queries.length === 0) return `internal ${delegate}`;
return `internal ${delegate}?${queries.join('&')}`;
};

Expand Down