API篇
hideLoading
Taro.hideLoading
微信真机上会同时关闭Taro.showToast
setState
- 初始化
setState
最佳时机componentDidMount
,在componentWillMount
的setState
的回调中再次setState
在H5
模式下会失效。(小程序:正常,H5:异常)
map
- 在
state
挂载的值为空数组的情况下,异步赋值,导致节点异常。(H5:异常,小程序:正常)
map
外层总是用一层组件包裹
组件篇
Image
- 实际H5实现是有一层包装层
ScrollView
ScrollView
容器内第一个元素,慎用margin-top
撑高度。 会破坏原始定高,导致少量内容却有滚动条。(小程序:异常,H5:正常)- 在小程序中默认存在
position: relative;
。(H5表现正常)
hidden异常
通过 state
数据控制显隐&#