mirror of
https://github.com/JefferyHcool/BiliNote.git
synced 2026-05-07 05:43:01 +08:00
refactor(backend): 更新默认提供商路径获取方法并配置前端请求基础 URL
- 新增 get_builtin_providers_path 函数以动态获取内置提供商 JSON 文件路径 - 修改 seed_default_providers 函数,使用新的路径获取方法 - 更新前端请求工具,配置 API 基础 URL 以适应不同环境
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
import axios from 'axios'
|
||||
|
||||
const request = axios.create({
|
||||
baseURL: '/api', // 默认请求路径前缀
|
||||
baseURL: import.meta.env.VITE_API_BASE_URL || 'http://localhost:8000',
|
||||
timeout: 10000,
|
||||
})
|
||||
|
||||
|
||||
Reference in New Issue
Block a user