refactor: 使用 vben 自带的 paramsSerializer 枚举,替代原本自己封装的方法

pull/62/head
YunaiV 2025-03-29 20:13:39 +08:00
parent 4fb83d3883
commit 584f107ae1
1 changed files with 1 additions and 4 deletions
packages/effects/request/src/request-client

View File

@ -61,10 +61,7 @@ class RequestClient {
responseReturn: 'raw',
// 默认超时时间
timeout: 10_000,
// 处理请求参数 默认使用 qs 库处理
paramsSerializer: (params) => {
return qs.stringify(params, { arrayFormat: 'repeat' });
},
paramsSerializer: 'repeat'
};
const { ...axiosConfig } = options;
const requestConfig = merge(axiosConfig, defaultConfig);