mirror of
https://github.com/react/react-native-devtools-frontend.git
synced 2026-10-01 01:38:07 +08:00
None of the breaking changes listed in https://github.com/mochajs/mocha/releases/tag/v7.0.0 appear to be relevant for us. R=jacktfranklin@chromium.org DISABLE_THIRD_PARTY_CHECK=Update Mocha Bug: 1068145 Change-Id: I4aec1e775595a0cfcfaa307a8aad7fc9abad22ca Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2137392 Commit-Queue: Tim van der Lippe <tvanderlippe@chromium.org> Reviewed-by: Jack Franklin <jacktfranklin@chromium.org>
2.2 KiB
2.2 KiB
camelcase 
Convert a dash/dot/underscore/space separated string to camelCase or PascalCase:
foo-bar→fooBar
Get professional support for 'camelcase' with a Tidelift subscription
Tidelift helps make open source sustainable for maintainers while giving companies
assurances about security, maintenance, and licensing for their dependencies.
Tidelift helps make open source sustainable for maintainers while giving companies
assurances about security, maintenance, and licensing for their dependencies.
Install
$ npm install camelcase
Usage
const camelCase = require('camelcase');
camelCase('foo-bar');
//=> 'fooBar'
camelCase('foo_bar');
//=> 'fooBar'
camelCase('Foo-Bar');
//=> 'fooBar'
camelCase('Foo-Bar', {pascalCase: true});
//=> 'FooBar'
camelCase('--foo.bar', {pascalCase: false});
//=> 'fooBar'
camelCase('foo bar');
//=> 'fooBar'
console.log(process.argv[3]);
//=> '--foo-bar'
camelCase(process.argv[3]);
//=> 'fooBar'
camelCase(['foo', 'bar']);
//=> 'fooBar'
camelCase(['__foo__', '--bar'], {pascalCase: true});
//=> 'FooBar'
API
camelCase(input, [options])
input
Type: string string[]
String to convert to camel case.
options
Type: Object
pascalCase
Type: boolean
Default: false
Uppercase the first character: foo-bar → FooBar
Security
To report a security vulnerability, please use the Tidelift security contact. Tidelift will coordinate the fix and disclosure.
Related
- decamelize - The inverse of this module
- uppercamelcase - Like this module, but to PascalCase instead of camelCase
- titleize - Capitalize every word in string
- humanize-string - Convert a camelized/dasherized/underscored string into a humanized one
License
MIT © Sindre Sorhus