Skip to main content
Using Deno in production at your company? Earn free Deno merch.
Give us feedback
Module

std/text/case.ts>toKebabCase

The Deno Standard Library
Latest
function toKebabCase
import { toKebabCase } from "https://deno.land/std@0.224.0/text/case.ts";

Converts a string into kebab-case.

Examples

Example 1

import { toKebabCase } from "https://deno.land/std@0.224.0/text/case.ts";

toKebabCase("deno is awesome"); // "deno-is-awesome"

Parameters

input: string

The string that is going to be converted into kebab-case

Returns

string

The string as kebab-case