MCPcopy Index your code
hub / github.com/angular-ui/ui-router / encodePath

Function encodePath

test/angular/1.6/angular.js:13766–13776  ·  view source on GitHub ↗

* Encode path using encodeUriSegment, ignoring forward slashes * * @param {string} path Path to encode * @returns {string}

(path)

Source from the content-addressed store, hash-verified

13764 * @returns {string}
13765 */
13766function encodePath(path) {
13767 var segments = path.split('/'),
13768 i = segments.length;
13769
13770 while (i--) {
13771 // decode forward slashes to prevent them from being double encoded
13772 segments[i] = encodeUriSegment(segments[i].replace(/%2F/g, '/'));
13773 }
13774
13775 return segments.join('/');
13776}
13777
13778function decodePath(path, html5Mode) {
13779 var segments = path.split('/'),

Callers 3

LocationHtml5UrlFunction · 0.70
LocationHashbangUrlFunction · 0.70

Calls 1

encodeUriSegmentFunction · 0.70

Tested by

no test coverage detected