️ feat: 更新后端URL环境变量为BACKEND_URL,以支持更灵活的配置

This commit is contained in:
2025-07-26 10:21:31 +08:00
parent 99e291654d
commit b92fce5c7c
2 changed files with 79 additions and 1 deletions

View File

@ -1,7 +1,7 @@
import axios from 'axios'
import { camelToSnakeObj, snakeToCamelObj } from 'field-conv'
export const BACKEND_URL = process.env.NEXT_PUBLIC_API_BASE_URL || 'http://neo-blog-backend:8888'
export const BACKEND_URL = process.env.BACKEND_URL || 'http://neo-blog-backend:8888'
const isServer = typeof window === 'undefined'