(str: string, upperCaseFirst?: boolean)
| 39 | } |
| 40 | |
| 41 | export function toCamelCase(str: string, upperCaseFirst?: boolean): string { |
| 42 | str = (str || '').toLowerCase().replace(/-(.)/g, function (match, group1) { |
| 43 | return group1.toUpperCase(); |
| 44 | }); |
| 45 | |
| 46 | if (upperCaseFirst && str) { |
| 47 | str = str.charAt(0).toUpperCase() + str.slice(1); |
| 48 | } |
| 49 | |
| 50 | return str; |
| 51 | } |
| 52 | |
| 53 | export const normalizeCssArray = zrUtil.normalizeCssArray; |
| 54 |
no outgoing calls
no test coverage detected
searching dependent graphs…