Javascript String camelCaseDash()

Description

Javascript String camelCaseDash()


String.prototype.camelCaseDash = function() {
  return this.replace( /(\-[a-z])/g, function( $1 ) {return $1.toUpperCase().replace( "-", "" );} );
};



PreviousNext

Related