MCPcopy
hub / github.com/angular-ui/ui-grid / encodeUriSegment

Function encodeUriSegment

lib/test/angular/1.8.0/angular.js:1603–1608  ·  view source on GitHub ↗

* We need our custom method because encodeURIComponent is too aggressive and doesn't follow * http://www.ietf.org/rfc/rfc3986.txt with regards to the character set (pchar) allowed in path * segments: * segment = *pchar * pchar = unreserved / pct-encoded / sub-delims / ":" / "

(val)

Source from the content-addressed store, hash-verified

1601 * / "*" / "+" / "," / ";" / "="
1602 */
1603function encodeUriSegment(val) {
1604 return encodeUriQuery(val, true).
1605 replace(/%26/gi, '&').
1606 replace(/%3D/gi, '=').
1607 replace(/%2B/gi, '+');
1608}
1609
1610
1611/**

Callers 2

encodePathFunction · 0.70
normalizePathFunction · 0.70

Calls 1

encodeUriQueryFunction · 0.70

Tested by

no test coverage detected