美文网首页
react native FlatList高性能列表 自定义

react native FlatList高性能列表 自定义

作者: 俗人彭jin | 来源:发表于2018-11-07 11:44 被阅读0次

自定义 loading

    onRefresh={() => {
        console.log('下拉加载触发的函数...')
   }}

这种只能出现1个菊花,不能自定义loading

用下面的替代即可,就能完成react-native自定义菊花的操作了

refreshControl={
                <RefreshControl
                    refreshing={true}  // 加载loading显示
                    onRefresh={() => {
                        console.log('下拉加载触发的函数...')
                    }}
                    title='loading...'
                    colors={['red']}
                    titleColor='red'
                    tintColor='red'
                />
            }

相关文章

网友评论

      本文标题:react native FlatList高性能列表 自定义

      本文链接:https://www.haomeiwen.com/subject/nagmxqtx.html