remove(fn)?{
????let?pond?=this.pond;
????pond.forEach((item,index)=>{
???????
????????if(item===fn){
????????????pond[index]=null;
????????????//item=null;
????????}
????})
};遍歷數(shù)組里的方法,想把滿足條件設(shè)置成空, 請(qǐng)問(wèn)為什么pond[index]=null?可以生效,而item=null;就不能用呢?
關(guān)于null的疑問(wèn)
天天向上學(xué)
2019-03-14 21:23:09