UNPKG
to-style
Version:
latest (1.3.3)
1.3.3
1.3.2
1.3.1
1.3.0
1.2.0
1.1.0
1.0.2
1.0.1
1.0.0
Convert style objects to style strings
github.com/radubrehar/toStyle
radubrehar/toStyle
to-style
/
src
/
stringUtils
/
camelize.js
13 lines
(10 loc)
•
250 B
JavaScript
View Raw
1
2
3
4
5
6
7
8
9
10
11
12
13
'use strict'
var
toCamelFn =
function
(
str, letter
){
return
letter ? letter.
toUpperCase
():
''
}
var
hyphenRe =
require
(
'./hyphenRe'
)
module
.
exports
=
function
(
str
){
return
str? str.
replace
(hyphenRe, toCamelFn):
''
}