-
Notifications
You must be signed in to change notification settings - Fork 2.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
- fix(angular): turn mf dts off by default #27198 - fix(react): turn mf dts off by default - fix(react): add migration to turn module federation dts off by default - fix(angular): add migration to turn module federation dts off by default <!-- Please make sure you have read the submission guidelines before posting an PR --> <!-- https://github.com/nrwl/nx/blob/master/CONTRIBUTING.md#-submitting-a-pr --> <!-- Please make sure that your commit message follows our format --> <!-- Example: `fix(nx): must begin with lowercase` --> <!-- If this is a particularly complex change or feature addition, you can request a dedicated Nx release for this pull request branch. Mention someone from the Nx team or the `@nrwl/nx-pipelines-reviewers` and they will confirm if the PR warrants its own release for testing purposes, and generate it for you if appropriate. --> ## Current Behavior <!-- This is the behavior we have today --> Nx already provides Typing support for Module Federation projects. The `@module-federation/enhanced` package has typing support turned on by default but it can be problematic. ## Expected Behavior <!-- This is the behavior we should expect with the changes in this PR --> Turn off `@module-federation/enhanced` own dts plugin providing typing support in favour of Nx's own typing support ## Related Issue(s) <!-- Please link the issue being fixed so it gets closed when this is merged. --> Fixes #27198
- Loading branch information
Showing
29 changed files
with
1,125 additions
and
49 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
7 changes: 6 additions & 1 deletion
7
packages/angular/src/generators/host/files/js/webpack.server.config.js__tmpl__
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,8 @@ | ||
const { withModuleFederationForSSR } = require('@nx/angular/module-federation'); | ||
const config = require('./module-federation.config'); | ||
module.exports = withModuleFederationForSSR(config) | ||
/** | ||
* DTS Plugin is disabled in Nx Workspaces as Nx already provides Typing support for Module Federation | ||
* The DTS Plugin can be enabled by setting dts: true | ||
* Learn more about the DTS Plugin here: https://module-federation.io/configure/dts.html | ||
*/ | ||
module.exports = withModuleFederationForSSR(config, { dts: false }); |
7 changes: 6 additions & 1 deletion
7
packages/angular/src/generators/host/files/ts/webpack.server.config.ts__tmpl__
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,9 @@ | ||
import { withModuleFederationForSSR } from '@nx/angular/module-federation'; | ||
import config from './module-federation.config'; | ||
|
||
export default withModuleFederationForSSR(config); | ||
/** | ||
* DTS Plugin is disabled in Nx Workspaces as Nx already provides Typing support for Module Federation | ||
* The DTS Plugin can be enabled by setting dts: true | ||
* Learn more about the DTS Plugin here: https://module-federation.io/configure/dts.html | ||
*/ | ||
export default withModuleFederationForSSR(config, { dts: false }); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
7 changes: 6 additions & 1 deletion
7
packages/angular/src/generators/remote/files/base-ts/webpack.server.config.ts__tmpl__
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,9 @@ | ||
import { withModuleFederationForSSR } from '@nx/angular/module-federation'; | ||
import config from './module-federation.config'; | ||
|
||
export default withModuleFederationForSSR(config); | ||
/** | ||
* DTS Plugin is disabled in Nx Workspaces as Nx already provides Typing support for Module Federation | ||
* The DTS Plugin can be enabled by setting dts: true | ||
* Learn more about the DTS Plugin here: https://module-federation.io/configure/dts.html | ||
*/ | ||
export default withModuleFederationForSSR(config, { dts: false }); |
8 changes: 7 additions & 1 deletion
8
packages/angular/src/generators/remote/files/base/webpack.server.config.js__tmpl__
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,9 @@ | ||
const { withModuleFederationForSSR } = require('@nx/angular/module-federation'); | ||
const config = require('./module-federation.config'); | ||
module.exports = withModuleFederationForSSR(config) | ||
|
||
/** | ||
* DTS Plugin is disabled in Nx Workspaces as Nx already provides Typing support for Module Federation | ||
* The DTS Plugin can be enabled by setting dts: true | ||
* Learn more about the DTS Plugin here: https://module-federation.io/configure/dts.html | ||
*/ | ||
module.exports = withModuleFederationForSSR(config, { dts: false }) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
7 changes: 6 additions & 1 deletion
7
packages/angular/src/generators/setup-mf/files/ts-webpack/webpack.config.ts__tmpl__
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,9 @@ | ||
import { withModuleFederation } from '@nx/angular/module-federation'; | ||
import config from './module-federation.config'; | ||
|
||
export default withModuleFederation(config); | ||
/** | ||
* DTS Plugin is disabled in Nx Workspaces as Nx already provides Typing support for Module Federation | ||
* The DTS Plugin can be enabled by setting dts: true | ||
* Learn more about the DTS Plugin here: https://module-federation.io/configure/dts.html | ||
*/ | ||
export default withModuleFederation(config, { dts: false }); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.