shenruisi / Stay

Stay is a local userscript manager and an extension sample for Safari on iOS/iPadOS.

Home Page:https://github.com/shenruisi/Stay/wiki

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Stay GM_xmlhttpRequest 不支持 FormData

ShaoxiongXu opened this issue · comments

Stay 版本: 2.6.2

测试代码

let formData = new FormData();
formData.append('a', 1);
formData.append('b', 2);
GM_xmlhttpRequest({
    method: 'POST',
    url: `${host}/api/xxx`,
    data: formData,
    onload: function (response) {

    },
    onerror: function (error) {

    }
});

使用 FormData 发送时 Request Payload:

image

image