<script> let arr = [ {id:3,name:'张三'}, {id:4,name:'李四'}, {id:5,name:'王五'}] let arr2 = arr.map(v => {return v.name}) console.dir(arr2) /* Array(3) 0: "张三" 1: "李四" 2: "王五" length: 3 */ </script>
京公网安备 11010502049817号