Conf:请求库替换,移除之前的flyIo,改用luch-request

This commit is contained in:
linxi
2024-10-18 14:48:22 +08:00
parent b0ac014816
commit cb6545ecd7
17 changed files with 1327 additions and 36 deletions
+31
View File
@@ -0,0 +1,31 @@
/**
* 默认的全局配置
*/
export default {
baseURL: '',
header: {},
method: 'GET',
dataType: 'json',
paramsSerializer: null,
// #ifndef MP-ALIPAY
responseType: 'text',
// #endif
custom: {},
// #ifdef H5 || APP-PLUS || MP-ALIPAY || MP-WEIXIN
timeout: 60000,
// #endif
// #ifdef APP-PLUS
sslVerify: true,
// #endif
// #ifdef H5
withCredentials: false,
// #endif
// #ifdef APP-PLUS
firstIpv4: false,
// #endif
validateStatus: function validateStatus(status) {
return status >= 200 && status < 300
}
}