js 更改对象中的属性名时间:2023-03-10 03:33:29 const json = JSON.parse(JSON.stringify(options).replace(/name/g,"label")); 注: 1、options是需要更改属性的对象 2、replace(/name/g,"label") ,将对象里所有属性为name的都修改成label