refactor(http): 简化请求处理逻辑并移除取消功能

移除 useRequest 和 http 模块中的取消请求功能
简化请求处理逻辑,移除双 token 刷新机制
优化错误处理流程,减少不必要的状态管理
This commit is contained in:
feige996
2025-09-25 14:23:46 +08:00
parent d584e1d58f
commit 780491290d
3 changed files with 23 additions and 150 deletions

View File

@@ -8,7 +8,7 @@ import { getFooAPI } from '@/api/foo'
// }
const initialData = undefined
const { loading, error, data, run, cancel } = useRequest<IFooItem>(() => getFooAPI('菲鸽'), {
const { loading, error, data, run } = useRequest<IFooItem>(() => getFooAPI('菲鸽'), {
immediate: true,
initialData,
})