Skip to content

Commit a0f0875

Browse files
gkalpakpetebacondarwin
authored andcommitted
chore(*): use ! as hash-prefix
Closes angular#341
1 parent aabd39b commit a0f0875

File tree

5 files changed

+11
-8
lines changed

5 files changed

+11
-8
lines changed

app/app.js

+3-1
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@ angular.module('myApp', [
77
'myApp.view2',
88
'myApp.version'
99
]).
10-
config(['$routeProvider', function($routeProvider) {
10+
config(['$locationProvider', '$routeProvider', function($locationProvider, $routeProvider) {
11+
$locationProvider.hashPrefix('!');
12+
1113
$routeProvider.otherwise({redirectTo: '/view1'});
1214
}]);

app/index-async.html

+2-2
Original file line numberDiff line numberDiff line change
@@ -46,8 +46,8 @@
4646
</head>
4747
<body ng-cloak>
4848
<ul class="menu">
49-
<li><a href="#/view1">view1</a></li>
50-
<li><a href="#/view2">view2</a></li>
49+
<li><a href="#!/view1">view1</a></li>
50+
<li><a href="#!/view2">view2</a></li>
5151
</ul>
5252

5353
<div ng-view></div>

app/index.html

+2-2
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,8 @@
1616
</head>
1717
<body>
1818
<ul class="menu">
19-
<li><a href="#/view1">view1</a></li>
20-
<li><a href="#/view2">view2</a></li>
19+
<li><a href="#!/view1">view1</a></li>
20+
<li><a href="#!/view2">view2</a></li>
2121
</ul>
2222

2323
<!--[if lt IE 7]>

bower.json

+2-1
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
"angular": "~1.5.0",
1010
"angular-route": "~1.5.0",
1111
"angular-loader": "~1.5.0",
12-
"angular-mocks": "~1.5.0"
12+
"angular-mocks": "~1.5.0",
13+
"html5-boilerplate": "^5.3.0"
1314
}
1415
}

e2e-tests/scenarios.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ describe('my app', function() {
1414
describe('view1', function() {
1515

1616
beforeEach(function() {
17-
browser.get('index.html#/view1');
17+
browser.get('index.html#!/view1');
1818
});
1919

2020

@@ -29,7 +29,7 @@ describe('my app', function() {
2929
describe('view2', function() {
3030

3131
beforeEach(function() {
32-
browser.get('index.html#/view2');
32+
browser.get('index.html#!/view2');
3333
});
3434

3535

0 commit comments

Comments
 (0)