Skip to content

Using a (non pure) getter for formGroup breaks the app with build optimizer #23

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

Closed
maxime1992 opened this issue Mar 26, 2019 · 2 comments
Assignees

Comments

@maxime1992
Copy link
Contributor

I wrote some E2E tests to catch errors in the demo app, and they were working locally but not on CI.

Turns out the difference is that on CI it's testing the app in prod mode with build optimizer turned ON.

I suspect the error is coming from the fact that our formGroup property (within the lib) is considered pure by the build optimizer, while it's not. As a result, some sub forms are not correctly populated with data.

@maxime1992 maxime1992 added the bug label Mar 26, 2019
@maxime1992
Copy link
Contributor Author

Also, I think it's coming from the getter because of that comment.

maxime1992 added a commit that referenced this issue Mar 26, 2019
This avoid the need to have a getter with side effect.
Cleaner, will open possibilities to reset the form and...

fixes #23
maxime1992 added a commit that referenced this issue Mar 26, 2019
This avoid the need to have a getter with side effect.
Cleaner, will open possibilities to reset the form and...

fixes #23
@maxime1992 maxime1992 self-assigned this Mar 26, 2019
maxime1992 added a commit that referenced this issue Mar 26, 2019
This avoid the need to have a getter with side effect.
Cleaner, will open possibilities to reset the form and...

fixes #23
@maxime1992
Copy link
Contributor Author

🎉 This issue has been resolved in version 2.0.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant