File tree Expand file tree Collapse file tree 3 files changed +11
-7
lines changed
Expand file tree Collapse file tree 3 files changed +11
-7
lines changed Original file line number Diff line number Diff line change @@ -9,7 +9,7 @@ import router from '@/router'
99import { ref , type WritableComputedRef } from 'vue'
1010
1111const axiosConfig = {
12- baseURL : '/api' ,
12+ baseURL : import . meta . env . VITE_API_BASE_URL || '/api' ,
1313 withCredentials : false ,
1414 timeout : 600000 ,
1515 headers : { }
Original file line number Diff line number Diff line change 1- import { hasPermission } from '@/utils/permission/index'
1+ import { hasPermission } from '@/utils/permission/index'
22import {
33 createRouter ,
4- createWebHistory ,
4+ createWebHashHistory ,
55 type NavigationGuardNext ,
66 type RouteLocationNormalized ,
7- type RouteRecordRaw ,
8- type RouteRecordName
7+ type RouteRecordName ,
8+ type RouteRecordRaw
99} from 'vue-router'
1010import useStore from '@/stores'
11- import { routes } from '@/router/routes'
11+ import { routes } from '@/router/routes'
12+
1213const router = createRouter ( {
13- history : createWebHistory ( import . meta. env . BASE_URL ) ,
14+ history : createWebHashHistory ( import . meta. env . BASE_URL ) ,
1415 routes : routes
1516} )
1617
Original file line number Diff line number Diff line change @@ -8,7 +8,10 @@ import DefineOptions from 'unplugin-vue-define-options/vite'
88const envDir = './env'
99// https://vitejs.dev/config/
1010export default defineConfig ( ( { mode } ) => {
11+ console . log ( 'Current Mode:' , mode ) ;
12+ console . log ( 'Loading Environment Variables from:' , process . cwd ( ) ) ;
1113 const ENV = loadEnv ( mode , envDir )
14+ console . log ( 'Loaded ENV:' , ENV ) ;
1215 const prefix = process . env . VITE_DYNAMIC_PREFIX || ENV . VITE_BASE_PATH ;
1316 const proxyConf : Record < string , string | ProxyOptions > = { }
1417 proxyConf [ '/api' ] = {
You can’t perform that action at this time.
0 commit comments