-
Notifications
You must be signed in to change notification settings - Fork 39
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
Upgrade to Angular V9 #79
Comments
First major issue: angular/angular#34227 Lot's of code in the library is built that way... Another issue i'm running into while upgrading: angular/angular#31221 As I suspected, to early to upgrade with these 2 major issues. |
I guess the Angular team didn't really expect people to do complex logic in Input property setters. Personally I always use ngOnChanges for that purpose, but I can see the appeal of doing it in the setter. |
@magnusbakken When you want to react to things immediately that makes sense, especially when you want to control performance wise. Also, In complex scenarios, I find it more difficult to reason the behaviour when working through changes. Last point, putting all of the change handling code in ngOnChanges is sometimes to much and not clear (code wise). Anyway, that's my take on this... Just keep in mind, regardless of my personal approach, that the behaviour they created is not deterministic... for bound properties you get one type of behaviour and for unbound (static values) you get another... bad choice. |
Just remembered in another issue I have with it... When working with a complex UI component, such as a table, you find your self in scenarios when change detection triggers are not automatic. For example, working with template references where the template reference was created in another change detection section.
The main issue here is changing properties in code (usually When done through code, we can raise a This is why it's mandatory to catch it on the setter so we can trigger a change detection cycle. |
* remove tsickle * upgrade to latest 8 version * upgrade angular to v9 * upgrade ngx-buid-plus * upgrade material & layout * upgrade nguniversal * upgrade nrwl nx * fix type issues * workaround unsupported ngx-cache lib * align with v9 changes * sync with v9 * fix gh-pages DOC site build + SS PreRender * disable transpose matchTemplate because logic doesnt work with v9 * make lib build work and publish version * remove cdk-drag v7 compatibility code * fix(ngrid/drag): sneaky issue with PblDragDrop and AOT * update readme * refactor(ngrid): upgrade to angular 9 Partial work of #79
This issue will sum up the scope/work required to migrate to angular & material v9.
Upgrading the library code itself is actually the small portion of the work required.
Most of the work will be on compatibility and refactoring of code used by the build process
of the library and the demo/docs application.
I will track the progress of upgrading to angular v9 (including material plugins) here.
Update dependencies (angular v9, material v9, CLI, ng-packger, TS, webpack, etc...)
Make it run in dev mode, explore issues and quirks.
Turn IVY flag off (Use ViewEngine) and verify that:
Turn IVY Flag on and compile while fixing issues.
Pay attention to:
ngx-build-plus
plugins used in the app build processng-packger
compatibility with the task extensions / transformers (ng-cli-packagr-tasks
). Especially verify the SCSS build tasks and try to deprecate the copy assets tasks in favour of the built in copy feature ofng-packger
Go over all TODO references in the code and see if the "TODO" can be applied. This usually refer to:
Material plugins (mostly Drag & Drop), with legacy support for v7 and v8. Remove that support.Material plugins inheritance, wasn't doable before should be doable now.TypeScript language features that weren't possible before, but now with 3.7 are valid.Moved to #106
Blockers:
[IVY]: Fail to getcomponentFactoryResolver
from a child NgModuleRef angular/angular#35580Non Blockers:
First working version is published:
2.0.0-rc.0
, see PR, now merged tomaster
For anyone who wants to see the migration commits, see the v8-to-v9-migration branch
The text was updated successfully, but these errors were encountered: