MCPcopy
hub / github.com/angular-ui/ui-router / decodePath

Function decodePath

test/angular/1.7/angular.js:14398–14411  ·  view source on GitHub ↗
(path, html5Mode)

Source from the content-addressed store, hash-verified

14396}
14397
14398function decodePath(path, html5Mode) {
14399 var segments = path.split('/'),
14400 i = segments.length;
14401
14402 while (i--) {
14403 segments[i] = decodeURIComponent(segments[i]);
14404 if (html5Mode) {
14405 // encode forward slashes to prevent them from being mistaken for path separators
14406 segments[i] = segments[i].replace(/\//g, '%2F');
14407 }
14408 }
14409
14410 return segments.join('/');
14411}
14412
14413function normalizePath(pathValue, searchValue, hashValue) {
14414 var search = toKeyValue(searchValue),

Callers 1

parseAppUrlFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected