Report errors to a service

Navigate to a new screen and back

Animate a widget across screens

Cookbook

Navigation

Animate a widget across screens

1. Create two screens showing the same image

2. Add a Hero widget to the first screen

3. Add a Hero widget to the second screen

Interactive example

It’s often helpful to guide users through an app as they navigate from screen
to screen. A common technique to lead users through an app is to animate a
widget from one screen to the next. This creates a visual anchor connecting
the two screens.

Use the Hero widget
to animate a widget from one screen to the next.
This recipe uses the following steps:

Create two screens showing the same image.

Add a Hero widget to the first screen.

Add a Hero widget to the second screen.