📜  formdata 追加字符串数组 - 无论代码示例

📅  最后修改于: 2022-03-11 14:59:02             🧑  作者: Mango

代码示例1
let barArray = [{item: 'one'}, {item: 'two'}];

let data = FormData();

data.append('foo', JSON.stringify(barArray))

this.$inertia.post('/upload', data);