我正在使用javascript创建一个项目。我从json数组过滤数据时遇到问题。我想从具有最小日期的数组中删除重复的对象。这是数组:
var data = {
"success": [
{
"id": 49,
"title": "message",
"creation_date": "2019-06-14 13:58:11",
},
{
"id": 49,
"title": "asdasd",
"creation_date": "2019-06-14 12:25:46",
}
]
}
输出应如下所示:
[{
{
"id": 49,
"title": "message",
"creation_date": "2019-06-14 13:58:11",
}]