Files
doneit-web/src/app/store/loader.service.ts
T

29 lines
375 B
TypeScript
Raw Normal View History

import { Injectable } from '@angular/core';
@Injectable({
providedIn: 'root'
})
export class LoaderService {
private loadingList: {
name: string
}[] = []
constructor() { }
get loading(){
return this.loadingList.length != 0
}
push({name = ''}) {
this.loadingList.push({
name: name
})
}
pop({}) {
this.loadingList.pop()
}
}