Commit cf0fe5fa authored by Hixie's avatar Hixie

Assert that App(routes) is not null.

This is probably a sign that you're using fn2 still.
parent 75f10ba6
...@@ -32,7 +32,15 @@ class App extends StatefulComponent { ...@@ -32,7 +32,15 @@ class App extends StatefulComponent {
this.theme, this.theme,
this.routes, this.routes,
this.onGenerateRoute this.onGenerateRoute
}): super(key: key); }): super(key: key) {
assert(() {
'The "routes" argument to App() is required.';
'This might be a sign that you have not upgraded to our new Widgets framework.';
'For more details see: https://groups.google.com/forum/#!topic/flutter-dev/hcX3OvLws9c';
'...or look at our examples: https://github.com/flutter/engine/tree/master/examples';
return routes != null;
});
}
final String title; final String title;
final ThemeData theme; final ThemeData theme;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment