Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Advancing into new areas with Angular Elements ...

Advancing into new areas with Angular Elements & Ivy

Manfred Steyer

February 25, 2019
Tweet

More Decks by Manfred Steyer

Other Decks in Programming

Transcript

  1. @ManfredSteyer Advancing into new areas with Angular Elements & Ivy

    Manfred Steyer SOFTWAREarchitekt.at ManfredSteyer
  2. @ManfredSteyer About me… • Manfred Steyer • SOFTWAREarchitekt.at • Angular

    Trainings and Consultancy • Google Developer Expert (GDE) • External Angular Team Member Page ▪ 9 Manfred Steyer Public: Frankfurt, Stuttgart, Vienna In-House: everywhere http://softwarearchitekt.at/workshops
  3. @ManfredSteyer Selected Polyfills • webcomponents-loader.js • Loads Polyfills on demand

    • Custom Elements • Shadom DOM • Templates • native-shim.js • Needed for browsers that DO support polyfills • When downleveled to ES5 • Alternative: Differential Loading (providing ES5 + ES2015 bundles)
  4. @ManfredSteyer Angular Elements @NgModule({ imports: [BrowserModule], declarations: [DateComponent], entryComponents: [DateComponent]

    }) export class DateModule { constructor(private injector: Injector) { const DateElement = createCustomElement( DateComponent, { injector: this.injector }); customElements.define('date-picker', DateElement); } }
  5. @ManfredSteyer Where Ivy can help ✓ Widgets based on @angular/core,

    @angular/common  Libs like @angular/forms or @angular/router
  6. @ManfredSteyer Roadmap (details can change) • Ivy behind a flag

    • Try it out! Angular 8 (Spring 2019) • Ivy by default • No breaking changes Angular 9 (Fall 2019)
  7. @ManfredSteyer Summary Angular: full fledged SPAs Angular Elements: Lightweight Scenarios

    Widgets CMS Integration Enriching Existing Applications Ivy: Better Treeshakability