1
我正在尝试合并数组中的重复值对象但不工作...... 我的结果是这样的
这是我的代码
-
dataa = [
{
date: '07/05/2020 00:09',
id: '5920501995',
score: 0,
student: 'boon boon',
},
....]
source = from(this.dataa);
//group by age
example = this.source.pipe(
groupBy(person => person.id),
// return each item in group as array
mergeMap(group => group.pipe(toArray())));
subscribe = this.example.subscribe(val => console.log(val));
-