#StackBounty: #angular2 #polyfills Angular 2 srcdoc polyfill doesn't work

Bounty: 50

I’m using Angular 2 with angular-cli and I want to add srcdoc polyfill to support Microsoft Edge. So:

I added to package.json https://github.com/jugglinmike/srcdoc-polyfill

I imported import 'srcdoc-polyfill/srcdoc-polyfill.min'; in polyfills.ts.

I used it like:


By chance, if you ask me for IframeAutoHeight directive, here is the code:


  selector: '[tlIframeAutoHeight]'
export class IframeAutoHeightDirective {

  constructor(element: ElementRef, renderer: Renderer) {
    renderer.listen(element.nativeElement, 'load', () => {
        element.nativeElement.contentWindow.document.body.clientHeight + 'px'

Microsoft Edge 35 is ignoring srcdoc property, any ideas about what’s the problem?

Get this bounty!!!

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.