ng-is-loading
TypeScript icon, indicating that this package has built-in type declarations

1.0.2 • Public • Published

#Usage

##Module

@NgModule({
  imports: [NgLoadingModule.forRoot()],
  ...
})
export class AppModule {}

##Component

@Component({
   selector: "my-app",
   templateUrl: "./app.component.html",
   styleUrls: ["./app.component.css"]
 })
 export class AppComponent {
   @IsLoading(['short', 'long'])
   public readonly isLoading$: Observable<boolean>;
  
   @Loading('long')
   public getLongApi() {
     return api.post();
   }
 
   @Loading('short')
   public getShortApi() {
     return api.get();
   }
 }

You can use both decorators in any place of your application.

#Learn more

https://purecaesar.medium.com/requests-management-in-angular-7fd7b15a112e

/ng-is-loading/

    Package Sidebar

    Install

    npm i ng-is-loading

    Weekly Downloads

    0

    Version

    1.0.2

    License

    none

    Unpacked Size

    36.9 kB

    Total Files

    22

    Last publish

    Collaborators

    • purecaesar