| OLD | NEW |
| 1 library companyinfo; | 1 library companyinfo; |
| 2 | 2 |
| 3 import 'dart:html'; | 3 import 'dart:html'; |
| 4 import 'package:web_ui/web_ui.dart'; | 4 import 'package:web_ui/web_ui.dart'; |
| 5 import 'package:route_hierarchical/client.dart'; | 5 import 'package:route_hierarchical/client.dart'; |
| 6 | 6 |
| 7 class RootView extends WebComponent { | 7 class RootView extends WebComponent { |
| 8 RouteHandle route; | 8 RouteHandle route; |
| 9 @observable String currentRouteName; | 9 @observable String currentRouteName; |
| 10 | 10 |
| 11 inserted() { | 11 inserted() { |
| 12 ['home', 'companyInfo', 'portfolio'].forEach((routeName) => | 12 ['home', 'companyInfo', 'portfolio'].forEach((routeName) => |
| 13 route.getRoute(routeName) | 13 route.getRoute(routeName) |
| 14 .onRoute.listen((_) => currentRouteName = routeName)); | 14 .onRoute.listen((_) => currentRouteName = routeName)); |
| 15 } | 15 } |
| 16 | 16 |
| 17 removed() { | 17 removed() { |
| 18 route.discard(); | 18 route.discard(); |
| 19 } | 19 } |
| 20 } | 20 } |
| OLD | NEW |