File tree Expand file tree Collapse file tree 1 file changed +17
-3
lines changed Expand file tree Collapse file tree 1 file changed +17
-3
lines changed Original file line number Diff line number Diff line change @@ -28,15 +28,29 @@ of your views.
28
28
29
29
``` js
30
30
// 0.10.x
31
+ var routes = (
32
+ < Routes location= " history" >
33
+ < Route handler= {App}>
34
+ < Route name= " dashboard" handler= {Dashboard}/ >
35
+ < / Route>
36
+ < / Routes>
37
+ );
38
+
31
39
React .render (routes, el);
32
40
33
41
// 0.11.x
34
- Router .run (routes, function (Handler ) {
42
+ var routes = (
43
+ < Route handler= {App}>
44
+ < Route name= " dashboard" handler= {Dashboard}/ >
45
+ < / Route>
46
+ );
47
+
48
+ Router .run (routes, Router .HistoryLocation , function (Handler ) {
35
49
React .render (< Handler/ > , el);
36
50
});
37
51
38
- // or if using history location
39
- Router .run (routes, Router . HistoryLocation , function (Handler ) {
52
+ // or default to hash location
53
+ Router .run (routes, function (Handler ) {
40
54
React .render (< Handler/ > , el);
41
55
});
42
56
```
You can’t perform that action at this time.
0 commit comments