🐫 Converts string to camel case.

Syntax

TypeScript
import { camelCase } from '@opentf/std';

camelCase(str: string): string;

Parameters

  • str: The string to convert.

Returns

The camel-cased string.

Examples

TypeScript
camelCase('Foo Bar') //=> 'fooBar'

camelCase('--foo-bar--') //=> 'fooBar'

camelCase('__FOO_BAR__') //=> 'fooBar'
Last updated on
Edit this page