html - 属性不再被视为节点了吗?

标签 html dom

根据MDN ATTRIBUTE_NODE 已弃用。为什么属性不再拥有 nodeType ?它们不再被视为节点吗?

最佳答案

来自Attr :

Warning: In DOM Core 1, 2 and 3, Attr inherited from Node. This is no longer the case in DOM4. In order to bring the implementation of Attr up to specification, work is underway to change it to no longer inherit from Node. You should not be using any Node properties or methods on Attr objects.

关于html - 属性不再被视为节点了吗?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/17116946/

相关文章:

javascript - 在 img 的顶部显示一个 div

html - 如何在打印页面时显示一个div中的所有内容

java - 如何使用 HTML5 数据属性获取 session 属性

javascript - 安全地解开 jQuery 实例以获取包装的 DOM 元素

javascript - 仅在父点击而非子点击时触发事件

html - 固定标题表在调整窗口大小时变形

javascript - 网站显示为不安全,因为流媒体提供商不支持 SSL

jquery - 响应式列宽高尺寸

html - DIV间距的困难

javascript - 如何通过url知道图片的大小