camelcase
Advanced tools
Comparing version 1.2.0 to 1.2.1
@@ -5,4 +5,10 @@ 'use strict'; | ||
return str.trim(); | ||
}).filter(function (str) { | ||
return str.length; | ||
}).join('-'); | ||
if (!str.length) { | ||
return ''; | ||
} | ||
if (str.length === 1 || !(/[_.\- ]+/).test(str) ) { | ||
@@ -9,0 +15,0 @@ if (str[0] === str[0].toLowerCase() && str.slice(1) !== str.slice(1).toLowerCase()) { |
{ | ||
"name": "camelcase", | ||
"version": "1.2.0", | ||
"version": "1.2.1", | ||
"description": "Convert a dash/dot/underscore/space separated string to camelCase: foo-bar → fooBar", | ||
@@ -5,0 +5,0 @@ "license": "MIT", |
3261
23