()
| 387 | } |
| 388 | |
| 389 | getIndentString(): string { |
| 390 | const indentStringCounts = {} |
| 391 | |
| 392 | this.sources.forEach((source) => { |
| 393 | const indentStr = source.content._getRawIndentString() |
| 394 | |
| 395 | if (indentStr === null) |
| 396 | return |
| 397 | |
| 398 | if (!indentStringCounts[indentStr]) |
| 399 | indentStringCounts[indentStr] = 0 |
| 400 | indentStringCounts[indentStr] += 1 |
| 401 | }) |
| 402 | |
| 403 | return ( |
| 404 | Object.keys(indentStringCounts).sort((a, b) => { |
| 405 | return indentStringCounts[b] - indentStringCounts[a] |
| 406 | })[0] || '\t' |
| 407 | ) |
| 408 | } |
| 409 | |
| 410 | indent(indentStr?: string): this { |
| 411 | if (!arguments.length) { |
no test coverage detected