Skip to content

Commit

Permalink
chore(example): fix the print Delta JSON icon button
Browse files Browse the repository at this point in the history
  • Loading branch information
EchoEllet committed Nov 9, 2024
1 parent fee50a7 commit cbe21df
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions example/lib/main.dart
Original file line number Diff line number Diff line change
Expand Up @@ -86,8 +86,10 @@ class _HomePageState extends State<HomePage> {
icon: const Icon(Icons.output),
tooltip: 'Print Delta JSON to log',
onPressed: () {
ScaffoldMessenger.of(context).showSnackBar(
const SnackBar(content: Text('This is a snackbar')));
ScaffoldMessenger.of(context).showSnackBar(const SnackBar(
content:
Text('The JSON Delta has been printed to the console.')));
debugPrint(jsonEncode(_controller.document.toDelta().toJson()));
},
),
],
Expand Down

0 comments on commit cbe21df

Please sign in to comment.