(content: string)
| 165 | // splits " \t foo bar \n" into [" \t ","foo bar"," \n"] |
| 166 | // "foo bar" -> ["","foo bar",""] |
| 167 | function splitSurroundingWhitespace(content: string) { |
| 168 | const trimmed = content.trim() |
| 169 | const before = content.slice(0, content.indexOf(trimmed)) |
| 170 | const after = content.slice(content.indexOf(trimmed) + trimmed.length) |
| 171 | return [before, trimmed, after] |
| 172 | } |
no outgoing calls
no test coverage detected
searching dependent graphs…