Hyperlinkv0.8.0-beta.28

String

String.stripMarginconsteffect/String.ts:1049
(self: string): string

Strips a leading | margin prefix from every line.

Example (Stripping pipe margins)

import { String } from "effect"

const text = "  |hello\n  |world"
const result = String.stripMargin(text)
console.log(result) // "hello\nworld"
transforming
Source effect/String.ts:10491 lines
export const stripMargin = (self: string): string => stripMarginWith(self, "|")