( Notes ) Angular Elements

Rough notes on introduction to Angular Elements.

July 12, 2019
angular


ngx-build-plus is the build module to use.

  • Compiling Angular Elements
  • Spits out polyfills as well
  • Extends CLI
  • Builder script is added
  • Input properties and Output events work normally.
  • Use document.querySelector and addEventListener.
  • ref function from React to set component in context.
  • onMounting addEventListener for events from Angular Elements.
  • Passing data from react to custom elements -> de-serializes.
  • Passing data in simple types works really well; otherwise overhead.
  • Multiple root level components
  • Share data through service; both components exported.
  • Can be used in app within any framework.
  • Angular elements can be used in AngularJS.
  • prop name; ng-on-click_event; set & get on_name
  • patch in form value.
comments powered by Disqus