Returns the empty part if the given width is zero, else a text part at the given width filled with the optionally provided indent string. The default indent string is a single space character.
import {pipe} from 'effect'import {hIndent} from 'effect-tree'const twoSpaces = hIndent(2)// ‘ ’const singleX = pipe(1, hIndent('X'))// ‘X’const nothing = hIndent(0, 'no space')// ‘’ Copy
import {pipe} from 'effect'import {hIndent} from 'effect-tree'const twoSpaces = hIndent(2)// ‘ ’const singleX = pipe(1, hIndent('X'))// ‘X’const nothing = hIndent(0, 'no space')// ‘’
Optional
Returns the empty part if the given width is zero, else a text part at the given width filled with the optionally provided indent string. The default indent string is a single space character.
Example