Javascript String toObjectNotation()

Description

Javascript String toObjectNotation()

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



PreviousNext

Related