* Increases indentation level by 1, calls provided callback and then decreases indentation again. * Could be used for writing indented blocks of text: * * @example * ```ts * writer * .writeLine('{') * .withIndent(() => { * writer.writeLine('foo: 123'); * writ
(callback: (writer: this) => void)
| 100 | * @returns |
| 101 | */ |
| 102 | withIndent(callback: (writer: this) => void): this { |
| 103 | this.indent() |
| 104 | callback(this) |
| 105 | this.unindent() |
| 106 | return this |
| 107 | } |
| 108 | |
| 109 | /** |
| 110 | * Calls provided callback next time when new line is started. |
no test coverage detected