1// [email protected] downloaded from https://ga.jspm.io/npm:[email protected]/index.js 2 3/** 4 * Count how often a character (or substring) is used in a string. 5 * 6 * @param {string} value 7 * Value to search in. 8 * @param {string} character 9 * Character (or substring) to look for. 10 * @return {number} 11 * Number of times `character` occurred in `value`. 12 */ 13function ccount(t,e){const n=String(t);if("string"!==typeof e)throw new TypeError("Expected character");let r=0;let c=n.indexOf(e);while(-1!==c){r++;c=n.indexOf(e,c+e.length)}return r}export{ccount}; 14
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.