angular blast
play

Angular Blast! Rapid Fire ngUpgrade Sam Julien Auth0, Angular GDE - PowerPoint PPT Presentation

Angular Blast! Rapid Fire ngUpgrade Sam Julien Auth0, Angular GDE upgradingangularjs.com Wrangling Dependencies During ngUpgrade Take Inventory Inventory Steps 1. Look through package.json (or vendor folder). 2. What is this? 3. Where is


  1. Angular Blast! Rapid Fire ngUpgrade

  2. Sam Julien Auth0, Angular GDE upgradingangularjs.com

  3. Wrangling Dependencies During ngUpgrade

  4. Take Inventory

  5. Inventory Steps 1. Look through package.json (or vendor folder). 2. What is this? 3. Where is it used? 4. Identify potential troublemakers.

  6. Troublemakers ● Tightly coupled to AngularJS ● Often UI widgets ● Cannot be upgraded with ngUpgrade

  7. AngularJS Component to Rewrite Third Party AngularJS Pagination Directive

  8. Angular Component to Downgrade Third Party AngularJS Pagination Directive

  9. Angular Component to Downgrade Third Party AngularJS Pagination Directive

  10. Dependency Triage Determine: ● Ditch - not used anymore ● Upgrade - a new version for Angular 2+ (sometimes prefixed with "ngx" or "ng2") ● Rewrite - no upgrade but can do in house (often for directives or transclusion)

  11. Webpack for ngUpgrade

  12. AOT Do's and Don'ts Default exports Private template variables Arrow functions in useFactory or useValue Mixing AngularJS & Angular code

  13. @ngtools/webpack (For production builds.)

  14. webpack-merge (For multiple environments.)

  15. Migrating to RxJS

  16. "First migrate, then get fancy."

  17. Use toPromise

  18. Replace q.all with forkJoin

  19. Caveats! ● Three musketeers: ○ One delay, all delay ○ One fails, all fail (can be adjusted)

  20. Learn the basics of RxJS outside of Angular

  21. Thank you! @samjulien upgradingangularjs.com

Recommend


More recommend