Skip to main content
On this page

@std/text

Overview Jump to heading

Utility functions for working with text.

import { toCamelCase, compareSimilarity } from "@std/text";
import { assertEquals } from "@std/assert";

assertEquals(toCamelCase("snake_case"), "snakeCase");

const words = ["hi", "help", "hello"];

// Words most similar to "hep" will be at the front
assertEquals(words.sort(compareSimilarity("hep")), ["help", "hi", "hello"]);

Add to your project Jump to heading

deno add jsr:@std/text

See all symbols in @std/text on

Did you find what you needed?

Privacy policy