Nodejs Utililty Methods String Equal

List of utility methods to do String Equal

Description

The list of methods to do String Equal are organized into topic(s).

Method

equals(item)
String.prototype.equals = function (item) {
  return this == item;
};
equals(str)
String.prototype.equals = function(str) {
    return this === str;
};
equals(str)
String.prototype.equals = function(str){
  return this.trim().toLowerCase() == str.trim().toLowerCase();
equals(val)
'use strict';
String.prototype.equals = function (val) {
  var isEquals = false;
  if (this === val || this + '' === val + '') {
    isEquals = true;
  return isEquals;
};