pull/3348/head^2
Halil İbrahim Kalkan 6 years ago
commit ea928f8937

@ -1,5 +1,6 @@
import { LazyLoadService } from '@abp/ng.core';
import { LazyLoadService, LOADING_STRATEGY } from '@abp/ng.core';
import { Component, OnInit } from '@angular/core';
import { forkJoin } from 'rxjs';
@Component({
selector: 'app-root',
@ -12,14 +13,13 @@ export class AppComponent implements OnInit {
constructor(private lazyLoadService: LazyLoadService) {}
ngOnInit() {
this.lazyLoadService
.load(
['fontawesome-all.min.css', 'fontawesome-v4-shims.min.css'],
'style',
null,
'head',
'afterbegin',
)
.subscribe();
forkJoin(
this.lazyLoadService.load(
LOADING_STRATEGY.PrependAnonymousStyleToHead('fontawesome-v4-shims.min.css'),
),
this.lazyLoadService.load(
LOADING_STRATEGY.PrependAnonymousStyleToHead('fontawesome-all.min.css'),
),
).subscribe();
}
}

@ -1,5 +1,6 @@
import { LazyLoadService } from '@abp/ng.core';
import { LazyLoadService, LOADING_STRATEGY } from '@abp/ng.core';
import { Component, OnInit } from '@angular/core';
import { forkJoin } from 'rxjs';
@Component({
selector: 'app-root',
@ -10,15 +11,15 @@ import { Component, OnInit } from '@angular/core';
})
export class AppComponent implements OnInit {
constructor(private lazyLoadService: LazyLoadService) {}
async ngOnInit() {
this.lazyLoadService
.load(
['fontawesome-all.min.css', 'fontawesome-v4-shims.min.css'],
'style',
null,
'head',
'afterbegin'
ngOnInit() {
forkJoin(
this.lazyLoadService.load(
LOADING_STRATEGY.PrependAnonymousStyleToHead('fontawesome-v4-shims.min.css')
)
.subscribe();
this.lazyLoadService.load(
LOADING_STRATEGY.PrependAnonymousStyleToHead('fontawesome-all.min.css')
),
).subscribe();
}
}

Loading…
Cancel
Save