effect-io-ai

Package: effect
Module: String

String.trimStart

Removes whitespace from the start of a string.

Example (Trimming leading whitespace)

import { String } from "effect"
import * as assert from "node:assert"

assert.deepStrictEqual(String.trimStart(" a "), "a ")
assert.deepStrictEqual(String.trimStart("  hello world"), "hello world")

Signature

declare const trimStart: <A extends string>(self: A) => TrimStart<A>

Source

Since v2.0.0