Solution (at least as far as I can tell): ngAfterViewInit.
import {Component, AfterViewInit} from 'angular2/core'; export class Gallery implements AfterViewInit { ngAfterViewInit() { $('.gallery')['magnificPopup']({ delegate: 'a', type: 'image', gallery: { enabled: true } }); } }
Obviously, the independent parts of the class are ignored. The square bracket designation calling the method in ngAfterViewInit is necessary because the TS compiler complains about missing properties (true at compile time, but not at run time) when using dot notation.
source share