js判断变量是否为空字符串、null、undefined

let _isEmpty = (input) => {
  return input + '' === 'null' || input + '' === 'undefined' || input.trim?input.trim()=== '':input.replace(/^s+|s+$/gm,'')==='';
};
原文地址:https://www.cnblogs.com/ysk123/p/9483276.html