File: index.d.ts

package info (click to toggle)
node-decamelize 4.0.0-2
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, forky, sid, trixie
  • size: 136 kB
  • sloc: javascript: 52; makefile: 2
file content (20 lines) | stat: -rw-r--r-- 542 bytes parent folder | download | duplicates (13)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
/**
Convert a camelized string into a lowercased one with a custom separator: `unicornRainbow` → `unicorn_rainbow`.

@param string - The camelcase string to decamelize.
@param separator - The separator to use to put in between the words from `string`. Default: `'_'`.

@example
```
import decamelize = require('decamelize');

decamelize('unicornRainbow');
//=> 'unicorn_rainbow'

decamelize('unicornRainbow', '-');
//=> 'unicorn-rainbow'
```
*/
declare function decamelize(string: string, separator?: string): string;

export = decamelize;