【发布时间】:2022-11-07 16:56:57
【问题描述】:
如何在 React JS 中检索多维数组中的值?告诉我答案
"result": {
"task": "Hello",
"data": [
{
"title": "Sample data one",
"subtitle": "Sample subtitle data one",
"amount": 100
},
{
"title": "Sample data two",
"subtitle": "Sample subtitle data two",
"amount": 200
},
{
"title": "Sample data three",
"subtitle": "Sample subtitle data three",
"amount": 300
}
]
}
【问题讨论】:
-
获取倾斜列表 array.result.data.map(item => item.title)
-
你试过什么了?
标签: reactjs arrays json dictionary key