{"ScriptPreparationCode":"function camelize(str, $ucfirst) {\r\n if ($ucfirst === void 0) { $ucfirst = false; }\r\n var $return = str.replace(/^([A-Z])|[\\s-_]\u002B(\\w)/g, function (match, p1, p2) {\r\n return p2 ? p2.toUpperCase() : p1.toLowerCase();\r\n });\r\n return $ucfirst ? $return.charAt(0).toUpperCase() \u002B $return.slice(1) : $return;\r\n};\r\n\r\nfunction toCamelCase(str) {\r\n let s =\r\n str \u0026\u0026\r\n str\r\n .match(/[A-Z]{2,}(?=[A-Z][a-z]\u002B[0-9]*|\\b)|[A-Z]?[a-z]\u002B[0-9]*|[A-Z]|[0-9]\u002B/g)\r\n .map(x =\u003E x.slice(0, 1).toUpperCase() \u002B x.slice(1).toLowerCase())\r\n .join(\u0027\u0027);\r\n return s.slice(0, 1).toLowerCase() \u002B s.slice(1);\r\n};\r\n","TestCases":[{"Name":"camelize","Code":"camelize(\u0027some_database_field_name\u0027);\r\ncamelize(\u0027Some label that needs to be camelized\u0027);\r\ncamelize(\u0027some-javascript-property\u0027);\r\ncamelize(\u0027some-mixed_string with spaces_underscores-and-hyphens\u0027);\r\n","IsDeferred":false},{"Name":"toCamelCase","Code":"toCamelCase(\u0027some_database_field_name\u0027);\r\ntoCamelCase(\u0027Some label that needs to be camelized\u0027);\r\ntoCamelCase(\u0027some-javascript-property\u0027);\r\ntoCamelCase(\u0027some-mixed_string with spaces_underscores-and-hyphens\u0027);\r\n","IsDeferred":false}]}