📜  颤动的小吃店颜色 - Dart 代码示例

📅  最后修改于: 2022-03-11 14:48:05.207000             🧑  作者: Mango

代码示例2
final snackBar = SnackBar(
  content: Text('Yay! A SnackBar!'),
  action: SnackBarAction(
    label: 'Undo',
    onPressed: () {
      // Some code to undo the change.
    },
  ),
);

 // Find the Scaffold in the widget tree and use
 // it to show a SnackBar.
 Scaffold.of(context).showSnackBar(snackBar);