Sha256: 1418a0f08e800adcb928a5cef344af3d33bd75b8fd9f670c2bcf9b2d7012908c
Contents?: true
Size: 250 Bytes
Versions: 31
Compression:
Stored size: 250 Bytes
Contents
/** * convert dashes and underscore strings into camelCase strings * @param {string} str * @returns {string} */ export function toCamelCase(str) { return str .split(/-|_/) .reduce((a, b) => a + b.charAt(0).toUpperCase() + b.slice(1)) }
Version data entries
31 entries across 31 versions & 1 rubygems