2

I am developing a component for the WiX website builder using Angular 2. There is requirement that the WiX proprietary library UI-Lib be used.

To create a popup dialog in the library, I need to call the API

var popup = Wix.UI.create({ctrl: 'Popup', options: {}});

where one of the values in the options object (content) is the inner HTML of the popup as a string.

What is the best way to do this from Angular 2 so that the inner HTML retains all of the advantages of Angular, including binding and child components?

If I simply hard code a string as the inner HTML, I will need to use a library like jQuery to control the popup at a much lower level of abstraction than Angular 2 allows, unless there is some way to have Angular control this inner HTML.

Ralph
  • 31,584
  • 38
  • 145
  • 282
  • In short, angular2 does not parse the content put into `[innerHTML]`. You may need dynamic component. You can check out my answer http://stackoverflow.com/a/39008455/1810391 . – John Siu Aug 23 '16 at 15:08

0 Answers0