routes.dart 881 B

1234567891011121314151617181920212223242526272829
  1. /*
  2. * fluro
  3. * A Posse Production
  4. * http://goposse.com
  5. * Copyright (c) 2018 Posse Productions LLC. All rights reserved.
  6. * See LICENSE for distribution and usage details.
  7. */
  8. import 'package:fluro/fluro.dart';
  9. import 'package:flutter/material.dart';
  10. import './route_handlers.dart';
  11. class Routes {
  12. static String root = "/";
  13. static String demoSimple = "/demo";
  14. static String demoFunc = "/demo/func";
  15. static String deepLink = "/message";
  16. static void configureRoutes(Router router) {
  17. router.notFoundHandler = new Handler(handlerFunc: (BuildContext context, Map<String, List<String>> params) {
  18. print("ROUTE WAS NOT FOUND !!!");
  19. });
  20. router.define(root, handler: rootHandler);
  21. router.define(demoSimple, handler: demoRouteHandler);
  22. router.define(demoFunc, handler: demoFunctionHandler);
  23. router.define(deepLink, handler: deepLinkHandler);
  24. }
  25. }