Skip to content

如何判断一个对象是否为空对象? ​

js
function checkNullObj(obj) {
  return Object.keys(obj).length === 0;
}