I've done everything by the tutorial ( https://angular.io/guide/animations ), but I have the error: menu-navigation.component.html:1 ERROR Error: Found the synthetic property @slideTop. Please include either "BrowserAnimationsModule" or "NoopAnimationsModule" in your application.
menu-navigation.component.html:1 ERROR Error: Found the synthetic property @slideTop. Please include either "BrowserAnimationsModule" or "NoopAnimationsModule" in your application.
I read everything about it but did not find the answer on how to resolve it.
Files:
So I did:
I tried:
Guys, help me :) I am stuck for already a few days.
UPDATE: Finally, I found the answer after testing on a new empty project
If you defined "animations" to the component (prop), then you can use them only inside its component (its own html), but not within a parent layout.
Instead of "" you must move its amination inside that component (app-animated-comp).
BrowserAnimationsModule is an package you need to add in your app.module
https://material.angular.io/guide/getting-started
import {BrowserAnimationsModule} from '@angular/platform-browser/animations';
@NgModule({
...
imports: [BrowserAnimationsModule],
...
})
export class PizzaPartyAppModule { }
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.