gns3-web-ui/src/main.ts

21 lines
711 B
TypeScript
Raw Normal View History

2018-12-10 14:08:47 +01:00
import 'hammerjs';
import { enableProdMode, ApplicationRef } from '@angular/core';
2017-09-25 13:07:52 +02:00
import { platformBrowserDynamic } from '@angular/platform-browser-dynamic';
import { AppModule } from './app/app.module';
import { environment } from './environments/environment';
import { enableDebugTools } from '@angular/platform-browser';
2017-09-25 13:07:52 +02:00
if (environment.production) {
enableProdMode();
}
platformBrowserDynamic().bootstrapModule(AppModule)
.then(moduleRef => {
const applicationRef = moduleRef.injector.get(ApplicationRef);
const componentRef = applicationRef.components[0];
// allows to run `ng.profiler.timeChangeDetection();`
enableDebugTools(componentRef);
})
.catch(err => console.log(err));