medikoo / es5-ext

ECMAScript extensions (with respect to upcoming ECMAScript features)
ISC License
174 stars 85 forks source link

Consider introduction of Object.isValue #54

Closed medikoo closed 7 years ago

medikoo commented 7 years ago

It would be as:

module.exports = function (value) {
  return ((value !== undefined) && (value !== null));
};

It would find use cases in environments, where we would prefer to have value != null checks more self explanatory (and in which we strictly would not want to rely on sloppy == operator)

medikoo commented 7 years ago

Published with v0.10.15