@newdash/newdash
Version:
javascript/typescript utility library
25 lines (24 loc) • 563 B
TypeScript
/**
* Converts `string` to
* [kebab case](https://en.wikipedia.org/wiki/Letter_case#Special_case_styles).
*
* @since 5.6.0
* @category String
* @param string The string to convert.
* @returns Returns the kebab cased string.
* @see camelCase, lowerCase, snakeCase, startCase, upperCase, upperFirst
* @example
*
* ```js
* kebabCase('Foo Bar')
* // => 'foo-bar'
*
* kebabCase('fooBar')
* // => 'foo-bar'
*
* kebabCase('__FOO_BAR__')
* // => 'foo-bar'
* ```
*/
export declare function kebabCase(string: string): string;
export default kebabCase;