【发布时间】:2022-11-02 16:36:25
【问题描述】:
我正在学习 Flutter,现在正在学习做导航。但是查看不同地方的关键字上下文让我感到困惑:
Navigator.push(context, MaterialPageRoute<void>(
builder: (BuildContext context) {
return Scaffold(
appBar: AppBar(title: Text('My Page')),
body: Center(
child: TextButton(
child: Text('POP'),
onPressed: () {
Navigator.pop(context);
},
),
),
);
},
));
谁能解释一下语境代表在每种情况下。谢谢
【问题讨论】:
标签: flutter