6.69 GB
45,738 files
Updated about 2 months ago
Name
Size
.github
example
test
.eslintrc437 Bytes
xet
CHANGELOG.md4.1 kB
xet
LICENSE1.07 kB
xet
README.md1.98 kB
xet
index.js1.39 kB
xet
package.json1.85 kB
xet
README.md

camelize Version Badge

github actions coverage License Downloads

npm badge

recursively transform key strings to camel-case

example

var camelize = require('camelize');
var obj = {
    fee_fie_foe: 'fum',
    beep_boop: [
        { 'abc.xyz': 'mno' },
        { 'foo-bar': 'baz' }
    ]
};
var res = camelize(obj);
console.log(JSON.stringify(res, null, 2));

output:

{
  "feeFieFoe": "fum",
  "beepBoop": [
    {
      "abcXyz": "mno"
    },
    {
      "fooBar": "baz"
    }
  ]
}

methods

var camelize = require('camelize')

camelize(obj)

Convert the key strings in obj to camel-case recursively.

install

With npm do:

npm install camelize

To use in the browser, use browserify.

license

MIT

Total size
6.69 GB
Files
45,738
Last updated
Sep 12
Pre-warmed CDN
US EU US EU

Contributors