提交 662a6597 编写于 作者: 雪洛's avatar 雪洛

docs: 更新setAttribute注意事项

上级 51a9928d
......@@ -56,7 +56,7 @@
**注意**
- setAttribute从HBuilderX 3.93起,调整为只能保存string类型属性值,需要保存其它类型数据请使用dataset属性。
- 为保证多端一致setAttribute不应用于修改本文档中的UniElement属性,如有此类需求应使用element.xxx设置,如element.scrollTop
- 为保证多端一致setAttribute不应用于修改本文档中的UniElement属性,如有此类需求应使用element.xxx设置,如element.scrollTop。其余绑定到内置组件的属性也尽量使用数据驱动而不是绕过vue去设置。
<!-- CUSTOMTYPEJSON.UniElement.methods.setAttribute.param -->
......@@ -72,7 +72,7 @@
**注意**
- getAttribute返回值从HBuilderX 3.93起,调整为string类型,不要使用此方法获取非string类型的属性值。如有非string需求,请使用对象的点操作符直接访问dateset属性,不通过getAttribute方法。
- 为保证多端一致getAttribute不应用于获取本文档中的UniElement属性,如有此类需求应使用element.xxx获取,如element.scrollTop
- 为保证多端一致getAttribute不应用于获取本文档中的UniElement属性,如有此类需求应使用element.xxx获取,如element.scrollTop
<!-- CUSTOMTYPEJSON.UniElement.methods.getAttribute.param -->
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册