Skip to content
Set of string conversion functions
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
test
.gitignore
LICENSE
README.md
camel2hyphen.js
hyphen2camel.js
index.js
package.json

README.md

string-convert

Set of string conversion functions

Installation

npm install string-convert --save

Methods

hyphen2camel

Converts hyphenated string to camelcase string

Example:

var hyphen2camel = require('string-convert/hyphen2camel');
hyphen2camel('min-width'); // minWidth
hyphen2camel('-moz-transition'); // MozTransition

camel2hyphen

Converts camel case string to hyphenated string

Example:

var camel2hyphen = require('string-convert/camel2hyphen');
camel2hyphen('minWidth');  // min-width
camel2hyphen('MozTransition'); //-moz-transition 
You can’t perform that action at this time.