MCPcopy
hub / github.com/Effect-TS/effect / string

Function string

packages/printer/src/internal/doc.ts:815–825  ·  view source on GitHub ↗
(str: string)

Source from the content-addressed store, hash-verified

813
814/** @internal */
815export const string = (str: string): Doc.Doc<never> => {
816 return cats(
817 str.split("\n").map((s) =>
818 s.length === 0
819 ? empty
820 : s.length === 1
821 ? char(s)
822 : text(s)
823 )
824 )
825}
826
827/** @internal */
828export const surround = dual<

Callers

nothing calls this directly

Calls 5

catsFunction · 0.85
splitMethod · 0.80
charFunction · 0.70
textFunction · 0.70
mapMethod · 0.65

Tested by

no test coverage detected