Skip to content

Instantly share code, notes, and snippets.

@arturovt
Created July 28, 2019 13:28
Show Gist options
  • Save arturovt/3433237bfa6168093b27d6e0ce3a9b0e to your computer and use it in GitHub Desktop.
Save arturovt/3433237bfa6168093b27d6e0ce3a9b0e to your computer and use it in GitHub Desktop.
export class AppModule {
public static ngModuleDef = defineNgModule({
type: AppModule,
imports: [BrowserModule],
declarations: [AppComponent],
bootstrap: [AppComponent]
});
public static ngInjectorDef = defineInjector({
factory: () => new AppModule(
inject(ComponentFactoryResolver)
),
imports: [BrowserModule]
});
constructor(resolver: ComponentFactoryResolver) {}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment