-
Notifications
You must be signed in to change notification settings - Fork 207
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
Unable to use esbuild plugins in native-federation #665
Comments
@thefirst24 please provide a reproducible stackblitz example as provided in the template you used to create this issue. |
Hi @rainerhahnekamp , I'm encountering similar issue here. i think just a your example app should be proving it. module-federation-plugin/libs/native-federation/src/builders/build/builder.ts Lines 161 to 173 in 434a94e
it looks like plugins are hard coded to buildApplication I could be wrong here, but I would really need a way to provide some plugins, any help or pointers would be great, thanks in advance |
Also having this issue. Need esbuild plugins for monaco-editor and some other custom ones that are applied. native-federation either overrides the plugins at build time preventing my plugins from running, or during
I am using the |
Guys, can someone please reproduce this in our stackblitz template which we are already providing? |
Yes, will do that soon |
@rainerhahnekamp Here is the minimal stackblitz. I changed the esbuild and serve-original builders to You can see that trying to Running I've been trying to tackle this for a few days so I'm somewhat familiar with what might be happening behind the scenes, so feel free to let me know if you have any further questions. The reason I am running into this issue is that I am trying to migrate a project from webpack/module-federation to esbuild/native-federation. I was using some webpack plugins during that process (specifically, |
Hey Jason, thanks for that detailed information. It is now up to us to fix it. I've assigned the issue me. |
I know you probably have a lot on your plate. Could you please update us after investigating when you have an expected date when this might be fixed/available? The reason I was so quickly moving to native-federation is that some other package update broke module-federation on my project. Instead of digging too much into that, I decided to simply use the effort on the migration to native-federation. So things are fairly broken at the moment. In the meantime, I am going to fork and investigate a fix myself just to try to keep moving. Thanks again. |
@YeomansIII, yes this time of the year is always crazy. Giving my current tasks, it is going to be the end of December |
Are you accepting PRs? |
Yes, it is still required that one of us reviews it, but it will definitely speed up the whole thing |
With what library do you have an issue?
native-federation
Reproduction of the bug/regression with instructions
Full error:
Error: Schema validation failed with the following errors:
Data path "" must NOT have additional properties(plugins).
at name (node_modules@angular-devkit\architect\src\architect.js:228:19)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
I logged builderName variable in _validateOptionsFactory in architect.js line and it print out "@angular-devkit/build-angular:application" for some reason
Expected behavior
Successfully build the application with esbuild plugins.
Versions of Native/Module Federation, Angular, Node, Browser, and operating system
"dependencies": {
"@angular/animations": "18.2.0",
"@angular/common": "18.2.0",
"@angular/compiler": "18.2.0",
"@angular/core": "18.2.0",
"@angular/forms": "18.2.0",
"@angular/platform-browser": "18.2.0",
"@angular/platform-browser-dynamic": "18.2.0",
"@angular/router": "18.2.0",
},
"devDependencies": {
"@angular-architects/module-federation": "^18.0.6",
"@angular-architects/native-federation": "^18.2.2",
"@angular-builders/custom-esbuild": "^18.0.0",
"@angular-devkit/build-angular": "^18.2.0",
"@angular-devkit/core": "18.2.0",
"@angular-devkit/schematics": "18.2.0",
"@angular/build": "^18.2.8",
"@angular/cdk": "18.2.0",
"@angular/cli": "~18.2.0",
"@angular/compiler-cli": "18.2.0",
"@nx/angular": "19.6.1",
"@nx/devkit": "19.6.1",
"@nx/jest": "19.6.1",
"@nx/js": "19.6.1",
"@nx/playwright": "19.6.1",
"@nx/plugin": "19.6.1",
"@nx/web": "19.6.1",
"@nx/webpack": "19.6.1",
"@nx/workspace": "19.6.1",
"nx": "19.6.1",
"typescript": "5.5.4",
}
Other information
No response
I would be willing to submit a PR to fix this issue
The text was updated successfully, but these errors were encountered: