MCPcopy Create free account
hub / github.com/bclinkinbeard/angular / beginsWith

Function beginsWith

test/fixtures/foo.js:9202–9206  ·  view source on GitHub ↗

* * @param {string} begin * @param {string} whole * @returns {string} returns text from whole after begin or undefined if it does not begin with * expected string.

(begin, whole)

Source from the content-addressed store, hash-verified

9200 * expected string.
9201 */
9202function beginsWith(begin, whole) {
9203 if (whole.indexOf(begin) === 0) {
9204 return whole.substr(begin.length);
9205 }
9206}
9207
9208
9209function stripHash(url) {

Callers 3

LocationHtml5UrlFunction · 0.85
LocationHashbangUrlFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected