Skip to main content
Module

x/core_fn/uncurry/string/mod.ts>startsWith

A collection of built-in object method and property as currying function
Latest
variable startsWith
import { startsWith } from "https://deno.land/x/core_fn@v1.0.0-beta.16/uncurry/string/mod.ts";

Checks if a string starts with the provided substring.

Examples

Example 1

// Basic
startsWith('hello', 'hello world') // true
startsWith('good', 'hello world') // false

type

(val: string, target: string) => boolean