0
我試圖尋找蒙戈,看是否有在我的數組的字符串被我「images.src.large」使用:搜索對象的數組中蒙戈包含在陣列中的任何值
字符串搜索:什麼將是我的蒙戈集合
['/california/los-angeles/pool.jpg','/california/los-angeles/pizza.jpg']
樣品:
{
"_id": someNumber,
"name: "Name 1",
"images": [
{
"title": "Title 1",
"src": {
"small": "/california/los-angeles/pool-small.jpg",
"medium": "/california/los-angeles/pool-medium.jpg",
"large": "/california/los-angeles/pool.jpg"
}
},
{
"title": "Title 2",
"src": {
"small": "/california/los-angeles/oven-small.jpg",
"medium": "/california/los-angeles/oven-medium.jpg",
"large": "/california/los-angeles/oven.jpg"
}
}
],
},
{
"_id": someOtherNumber,
"name: "Name 2",
"images": [
{
"title": "Landscape",
"src": {
"small": "/alaska/badger/dog-small.jpg",
"medium": "/alaska/badger/dog-medium.jpg",
"large": "/alaska/badger/dog.jpg"
}
},
{
"title": "Food",
"src": {
"small": "/alaska/badger/pizza-small.jpg",
"medium": "/alaska/badger/pizza-medium.jpg",
"large": "/alaska/badger/pizza.jpg"
}
}
],
},
{
"_id": aDifferentNumber,
"name: "Bridge",
"images": [
{
"title": "Store",
"src": {
"small": "/hawaii/kilauea/pool-small.jpg",
"medium": "/hawaii/kilauea/pool-medium.jpg",
"large": "/hawaii/kilauea/pool.jpg"
}
},
{
"title": "Home",
"src": {
"small": "/hawaii/kilauea/tree-small.jpg",
"medium": "/hawaii/kilauea/tree-medium.jpg",
"large": "/hawaii/kilauea/tree.jpg"
}
}
],
},
基本上,我想要做的是搜索我的收藏,看看是否正在使用的圖像通過搜索清「images.src.large」的值。