why the listView don't appear after use the spinner ??everyone can help?
xinwanggit opened this issue · comments
xinwanggit commented
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
})
})
}
..........
xinwanggit commented
I solved it