1 //js数组lambda表达式 2 //单个对象 3 var nubList = eval(data2[0]); 4 var nub = nubList.find(nub => nub.expressId == "00002"); 5 console.log(nub.expressId); 6 //查找数组 7 var nub1 = nubList.filter(nub => nub.expressId == "00002"); 8 console.log(nub1[0].expressId);
原文地址:https://www.cnblogs.com/Evan-Pei/p/10136775.html
时间: 2024-10-14 10:11:36