/play-ngx-dom-sprinkle

Applying Angular framework on existing HTML markup

Primary LanguageTypeScript

Angular DOM sprinkling

I.e. applying Angular framework on existing HTML and bootstrapping all component from there on the fly. With current approach, all AoT compatible (so no JiT compiler included).

See working live demo.

Inspiration / read

Hacks / workaround

  • @Inputs don't work, have to be manually restored (implemented)
  • Content projection works, but <ng-content select="..."> doesn't (projects everything, no matter what you put in select attribute).
  • ComponentFactory overrides all element attributes (e.g. class), which causes problems if you set anything on Host component (e.g. using @HostBindings).

Author: Marcin Ryzycki @ryzmen. Any ideas how to improve it, please give me a shout!