Exploring how to extend an Angular application by introducing a client plugin side architecture using web components.
It is based on the well-known tour of heroes tutorial, which can be found on Angular's official documentation
This is prototype, assembled for a Scotland's Angular Meetup talk, it is not production-ready code and should not be used as such.
Get Tour of Heroes tutoarial source code
Add Angular Elements dependency
Fire up console and run ng add @angular/elements
Hardcoded hero universe web component
- Introduce hero universe indicator component
- Add Custom Element schema ( schemas: [CUSTOM_ELEMENTS_SCHEMA] )
- hardcode into heroes component
client side plugin infrustructure
- Declare plugins through pluginHeroes global variable
- Dynamically load plugins through a heroes host component
- Remove Custom Elements schema