(str, suffix)
| 2276 | return res > max ? undefined : res; |
| 2277 | } |
| 2278 | function endsWith(str, suffix) { |
| 2279 | var expectedPos = str.length - suffix.length; |
| 2280 | return expectedPos >= 0 && str.indexOf(suffix, expectedPos) === expectedPos; |
| 2281 | } |
| 2282 | ts.endsWith = endsWith; |
| 2283 | function removeSuffix(str, suffix) { |
| 2284 | return endsWith(str, suffix) ? str.slice(0, str.length - suffix.length) : str; |
no test coverage detected
searching dependent graphs…