forked from bluesmoon/boomerang
-
Notifications
You must be signed in to change notification settings - Fork 294
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
SPA.markNavigationComplete() support
- Loading branch information
Showing
7 changed files
with
463 additions
and
13 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
...lates/05-angular/113-route-change-abld.js → ...lates/05-angular/114-route-change-abld.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
53 changes: 53 additions & 0 deletions
53
tests/page-templates/05-angular/117-route-change-markcomplete.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
<%= header %> | ||
<%= boomerangScript %> | ||
<base href="/pages/05-angular/04-route-change.html" /> | ||
<script src="../../vendor/angular/angular.js"></script> | ||
<script src="../../vendor/angular-resource/angular-resource.js"></script> | ||
<script src="../../vendor/angular-route/angular-route.js"></script> | ||
<script src="../../vendor/resourcetiming-compression/src/resourcetiming-decompression.js" type="text/javascript"></script> | ||
<script> | ||
window.angular_imgs = [5000]; | ||
|
||
window.angular_html5_mode = true; | ||
</script> | ||
<script src="support/app.js"></script> | ||
<div ng-app="app"> | ||
<div ng-view> | ||
</div> | ||
</div> | ||
<script src="117-route-change-markcomplete.js" type="text/javascript"></script> | ||
<script> | ||
|
||
// view a widget then come back so debugging (F5) is easier | ||
app.run(["$location", "$timeout", function($location, $timeout) { | ||
// issue a route change while the spa hard is still loading | ||
$timeout(function() { | ||
window.nav1time = BOOMR.now(); | ||
BOOMR.plugins.SPA.markNavigationComplete(); | ||
|
||
// now navigate to the second URL | ||
$location.url("/widgets/10"); | ||
|
||
// issue a route change while the spa soft is still loading | ||
$timeout(function() { | ||
window.nav2time = BOOMR.now(); | ||
BOOMR.plugins.SPA.markNavigationComplete(); | ||
|
||
$location.url("117-route-change-markcomplete.html"); | ||
}, 1000); | ||
}, 1000); | ||
}]); | ||
|
||
BOOMR_test.init({ | ||
testAfterOnBeacon: 3, | ||
Angular: { | ||
enabled: true | ||
}, | ||
ResourceTiming: { | ||
enabled: true | ||
}, | ||
instrument_xhr: true, | ||
autorun: false | ||
}); | ||
</script> | ||
<%= footer %> |
Oops, something went wrong.