Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Angular Material Progress Spinner not animated

I am trying to add an indeterminate spinner from Angular Material. I checked the official stack blitz example https://stackblitz.com/angular/nkabnxaenep. I compared the package jsons and cant find any differences. a am ahead a few minor versions. The determinate mode works though... I imported the correct module and there are no errors at runtime.

<mat-spinner mode="indeterminate"></mat-spinner>

not working spinner image

Any ideas? Tell me if you need more information.

like image 617
Gerolmed Avatar asked Sep 07 '26 21:09

Gerolmed


1 Answers

To enable the animations of Angular Material you have to import the BrowserAnimationsModule into your AppModule as mentioned in the 3rd step of the getting started guide.

imports: [
    BrowserModule,
    BrowserAnimationsModule,
    // NoopAnimationsModule,
    ...

Note: make sure to remove the NoopAnimationsModule from your project as well.

Update: The recommended way to install Angular Material nowadays is with ng add @angular/material, which should already set this up for you.

like image 150
Robin De Schepper Avatar answered Sep 12 '26 17:09

Robin De Schepper