Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
46 changes: 23 additions & 23 deletions src/content/learn/pathway/tutorial/listenable-builder.md
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,29 @@ class ArticleView extends StatelessWidget {
}
```

### Update your app to include the article view

Connect everything together by updating your `MainApp` to
include your completed `ArticleView`.

Replace your existing `MainApp` with this updated version:

```dart
class MainApp extends StatelessWidget {
const MainApp({super.key});

@override
Widget build(BuildContext context) {
return MaterialApp(
home: ArticleView(),
);
}
}
```

This change switches from the console-based test to the full UI
experience with proper state management.

### Listen for state changes

Wrap your UI in a [`ListenableBuilder`][] to listen for state changes,
Expand Down Expand Up @@ -399,29 +422,6 @@ This widget demonstrates a few important UI concepts:
- **Overflow handling**:
`TextOverflow.ellipsis` prevents text from breaking the layout.

### Update your app to include the article view

Connect everything together by updating your `MainApp` to
include your completed `ArticleView`.

Replace your existing `MainApp` with this updated version:

```dart
class MainApp extends StatelessWidget {
const MainApp({super.key});

@override
Widget build(BuildContext context) {
return MaterialApp(
home: ArticleView(),
);
}
}
```

This change switches from the console-based test to the full UI
experience with proper state management.

### Run the complete app

Hot reload your app one final time. You should now see:
Expand Down
Loading