例如,如果我正在这样做a.setAttribute("begin", b+".focus");
,它会显示在开发工具的 HTML 选项卡中,但它会被行为完全忽略(如果我begin="time1.focus"
直接在 html 中添加它就可以了)。
你如何将这些动态添加的属性暴露给行为?
还有其他方法可以添加它们吗?(createElement 和 document.write 除外)
PS:我已经尝试过使用 createAttribute + nodeValue + setAttributeNode 无济于事。