feat(nf): use native federation with ng builder instead of adapter #588
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
As long as native federation is a great idea i see great performance and architectural issue using literally 2 builders at once (app builder and adapter)
For example my app code:
All the federation artefacts (node packages, exposes, non-buildable libs etc) would built in other proccess:
I spent some amount of time thinking if i could do something about it and this PR is the result, i tried to leave comment on each potentially non-obvious line
Main idea is:
If you try it out you'll see:
2. pretty much the same speed
3. correct files and artefacts in console
3. same as build on start
4. faster rebuilds
5. transparent data in console
6. nice page reloading on edit any artefacts
One more thing - i understand that it is not a prod-ready code. Right now it's more about to validate if this idea has right to live, or is it failure even on PoC stage)
It would be my personal great achievement if this PR would be accepted. Appreciate any comments, thoughts, questions or additions, thank you in advance