array.fliter无法正确过滤出我想要的数组


var checked_list = state.files.filter(function(item, id){
        // console.log('click the ' + item.id);
        return item.id == id;
      });
      console.info(checked_list);

这是为什么呢?this.fileid=1的情况下也无法正确过滤出数组


array.fliter无法正确过滤出我想要的数组 >> node.js

这个答案描述的挺清楚的:
http://www.goodpm.net/postreply/node.js/1010000008224888/arrayfliter无法正确过滤出我想要的数组.html
posted @ 2017-07-17 21:23  赚它一个亿  阅读(114)  评论(0编辑  收藏  举报