error during evaluating file "app.js" length must be a positive 32-bit interger
1***@163.com
- 发布:2023-11-09 13:17
- 更新:2024-05-06 16:45
- 阅读:652
看到这条信息的兄弟们,务必删除 qs,下面贴上替代方法,或者自行 ChatGTP 下代码替换
function qsStringify(obj) {
const keyValuePairs = [];
for (let key in obj) {
if (obj.hasOwnProperty(key)) {
const value = obj[key];
const encodedKey = encodeURIComponent(key);
const encodedValue = encodeURIComponent(value);
keyValuePairs.push(`${encodedKey}=${encodedValue}`);
}
}
return keyValuePairs.join('&');
}