src/index.js
function addCamelCasedVersion(obj) {
  const regExp = /(-[a-z])/g
  const replace = str => str[1].toUpperCase()
  const newObj = {}
  for (const key in obj) {
    newObj[key] = obj[key]
    newObj[key.replace(regExp, replace)] = obj[key]
  }
  return newObj
}
function addCamelCasedVersion(obj) {
  const regExp = /(-[a-z])/g
  const replace = str => str[1].toUpperCase()
  const newObj = {}
  for (const key in obj) {
    newObj[key] = obj[key]
    newObj[key.replace(regExp, replace)] = obj[key]
  }
  return newObj
}
function addCamelCasedVersion ( obj ) { const regExp = / (-[a-z]) / g const replace = str => str [ 1 ] . toUpperCase ( ) const newObj = { } for ( const key in obj ) { newObj [ key ] = obj [ key ] newObj [ key . replace ( regExp , replace ) ] = obj [ key ] } return newObj }
Clones the object and adds a camel cased property version.
Clones the object and adds a camel cased property version .