Stagger works alongside query in order to animate the selected elements individually, one after the other, using a delay in between each segment of animation. This allows a much more dynamic animation as each element is rendered separately instead of everything at once. Using query() and stagger() together in this way allows for all sorts of possibilities when animating content within your components.
- [Instructor] Stagger works alongside query…in order to animate the selected elements individually…one after the other…using a delay in between each segment of an animation.…This allows a much more dynamic animation…as each element is rendered separately…instead of everything at once.…There actually isn't a whole lot to do to get this working.…We need to add stagger to our imports…and then just adjust our query.…
So here we have our present query.…Let's remove that and paste in a snippet for the new query.…You can see that almost all of it looks exactly the same.…We just have this extra piece here defining our stagger.…We're setting stagger to 100 milliseconds.…So what should happen is that…between each single block being animated…should be a staggered delay of 100 milliseconds.…
To see this in action,…save your file.…It'll recompile,…and then we'll pop over to the browser to check it out.…All right, going to advanced,…we can see our fade block fade out,…and now when we show spoons,…we can see that 100 millisecond delay…
- Installing the Angular CLI
- Creating a new project
- Verifying the animations package
- Configuring project routes
- Animating components
- Triggering animation between states
- Stepped and parallel animation
- Writing reusable animations
- Animating individual items with query and stagger
- Animating an existing Angular project
Skill Level Intermediate
1. Getting Ready to Animate
2. Enabling Angular Animations
3. Angular Animation Basics
4. Advanced Angular Animation
5. Animating an Existing Interface
6. Package for Distribution
Building the project1m 56s
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.