SuperYan - 【学习笔记——JavaScript】如何判断对象中属性是否存在? 的评论 https://www.hblyan.com/archives/114.html 推荐是使用 in 去判断 通常想到的方式是 Object.hasOwnProperty(prop) 或者是 遍历keys去 includes()hasOwnProperty function ...