refactor: update productionBasePath to empty string and adjust static resource handling for dashboard
This commit is contained in:
@@ -3,7 +3,7 @@ import { PHASE_DEVELOPMENT_SERVER } from "next/constants"
|
|||||||
|
|
||||||
const backendBaseUrl =
|
const backendBaseUrl =
|
||||||
process.env.NEXT_PUBLIC_API_BASE_URL?.trim() || "http://127.0.0.1:8083"
|
process.env.NEXT_PUBLIC_API_BASE_URL?.trim() || "http://127.0.0.1:8083"
|
||||||
const productionBasePath = "/dashboard"
|
const productionBasePath = ""
|
||||||
|
|
||||||
export default function nextConfig(phase: string): NextConfig {
|
export default function nextConfig(phase: string): NextConfig {
|
||||||
const config: NextConfig = {
|
const config: NextConfig = {
|
||||||
|
|||||||
@@ -3,4 +3,5 @@ ignoredBuiltDependencies:
|
|||||||
- unrs-resolver
|
- unrs-resolver
|
||||||
|
|
||||||
onlyBuiltDependencies:
|
onlyBuiltDependencies:
|
||||||
|
- '@parcel/watcher'
|
||||||
- msw
|
- msw
|
||||||
|
|||||||
@@ -69,7 +69,7 @@ func NewServer() (*iris.Application, error) {
|
|||||||
})
|
})
|
||||||
|
|
||||||
// 注册dashboard静态资源服务
|
// 注册dashboard静态资源服务
|
||||||
app.HandleDir("/dashboard", iris.Dir("dashboard/out"), iris.DirOptions{
|
app.HandleDir("/", iris.Dir("dashboard/out"), iris.DirOptions{
|
||||||
IndexName: "index.html",
|
IndexName: "index.html",
|
||||||
Compress: true,
|
Compress: true,
|
||||||
ShowList: false,
|
ShowList: false,
|
||||||
|
|||||||
Reference in New Issue
Block a user