MCPcopy Index your code
hub / github.com/angular-ui/ui-grid / parseAppUrl

Function parseAppUrl

lib/test/angular/1.5.0/angular.js:12127–12142  ·  view source on GitHub ↗
(relativeUrl, locationObj)

Source from the content-addressed store, hash-verified

12125
12126
12127function parseAppUrl(relativeUrl, locationObj) {
12128 var prefixed = (relativeUrl.charAt(0) !== '/');
12129 if (prefixed) {
12130 relativeUrl = '/' + relativeUrl;
12131 }
12132 var match = urlResolve(relativeUrl);
12133 locationObj.$$path = decodeURIComponent(prefixed && match.pathname.charAt(0) === '/' ?
12134 match.pathname.substring(1) : match.pathname);
12135 locationObj.$$search = parseKeyValue(match.search);
12136 locationObj.$$hash = decodeURIComponent(match.hash);
12137
12138 // make sure path starts with '/';
12139 if (locationObj.$$path && locationObj.$$path.charAt(0) != '/') {
12140 locationObj.$$path = '/' + locationObj.$$path;
12141 }
12142}
12143
12144
12145/**

Callers 2

LocationHtml5UrlFunction · 0.70
LocationHashbangUrlFunction · 0.70

Calls 2

urlResolveFunction · 0.70
parseKeyValueFunction · 0.70

Tested by

no test coverage detected