摘要:
// 1、配置路由import 'package:flutter/material.dart'; import 'pages/Tabs.dart'; import 'pages/Search.dart';import 'pages/Form.dart'; void main() => runApp( 阅读全文
摘要:
import 'pages/Form.dart'; void main() => runApp(MyApp()); class MyApp extends StatelessWidget { final routes = { '/': (contxt) => Tabs(), '/search': ( 阅读全文
摘要:
返回上一级// 返回到上一级页面Navigator.of(context).pop();12替换路由比如我们从用户中心页面跳转到了 registerFirst 页面,然后从 registerFirst 页面通过 pushReplacementNamed 跳转到了 registerSecond 页面。 阅读全文
摘要:
目录|-pages|-routes|—Routes.dart // routes/Routes.dartimport 'package:flutter/material.dart'; import '../pages/Tabs.dart';import '../pages/Form.dart';im 阅读全文
摘要:
RaisedButton( child: Text("跳转到搜索页面"), onPressed: (){ Navigator.of(context).push( MaterialPageRoute( builder: (BuildContext context){ return FormPage(t 阅读全文