Press n or j to go to the next uncovered block, b, p or k for the previous block.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 | 12x 409x 409x 409x 409x 1075x 1075x 899x 409x | export class StringUtils { static findLast(str: string, re = /[a-z0-9]/i, startNdx: number = -1): number { Eif (startNdx < 0 || startNdx > str.length) { startNdx = str.length - 1; } let found = false; while (!found && startNdx >= 0) { found = re.test(str.charAt(startNdx)); if (!found) startNdx--; } return startNdx; } } |