Is there a way to include a component inside an iframe in Angular 2?
This code doesn't work (it should render the angular component called component-b inside the iframe):
var doc = document.getElementById('iframe').contentWindow.document;
doc.open();
doc.write('<component-b></component-b>');
doc.close();
This code works (it renders a simple button inside the iframe):
var doc = document.getElementById('iframe').contentWindow.document;
doc.open();
doc.write('<button></button>');
doc.close();