ladjs / react-native-loading-spinner-overlay

:barber: React Native loading spinner overlay

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

why the listView don't appear after use the spinner ??everyone can help?

xinwanggit opened this issue · comments

I want to do:when switch to this page, visible===true, the spinner will exists. then when the fetch get the urls,the spinner disappear.. But why the listView can't appear, it's nothing

constructor(props) {
super(props);

this.state = {
  index:this.props.data,
  urls:null,
  visible:true,

.....

componentDidMount(){
InteractionManager.runAfterInteractions(()=>{
const that=this;
const params={index:that.state.index};
Fetchers.fetch(devicelisturl,'GET',params)
.then(function(set){
that.setState({
urls:set.items[0].domainBlacklist.split(','),
visible:false,
})
})
.catch(function(err){
Errhandler.err(err);
visible:false
})
})
}
..........

{rowdata} this._ondelete(rowID)}>

} />

I solved it