0
我有2個對象數組。如何獲得不匹配另一個對象的對象lodash
const a = [
{
name: 'John'
},
{
name: 'Adam'
}
]
const b = [
{
name: 'Adam'
}
]
我想要得到的數組中的對象是不一樣的,並且也得到在數組中同樣的對象。
const same = [
{
name: 'Adam'
}
]
const not_same = [
{
name: 'John'
}
]
使用lodash庫有可能嗎?
你有試過什麼嗎? –
自己嘗試一下,然後回到問題。提示:https://lodash.com/docs/4.17.4#find –