File tree 2 files changed +6
-8
lines changed
2 files changed +6
-8
lines changed Original file line number Diff line number Diff line change @@ -2,12 +2,10 @@ import path from 'path'
2
2
import { Alias , AliasOptions } from 'vite'
3
3
4
4
const PKG_ROOT = path . join ( __dirname , '../../' )
5
- export const APP_PATH = path . join ( __dirname , '../client/app' )
6
- export const SHARED_PATH = path . join ( __dirname , '../client/shared' )
7
- export const DEFAULT_THEME_PATH = path . join (
8
- __dirname ,
9
- '../client/theme-default'
10
- )
5
+ export const DIST_CLIENT_PATH = path . join ( __dirname , '../client' )
6
+ export const APP_PATH = path . join ( DIST_CLIENT_PATH , 'app' )
7
+ export const SHARED_PATH = path . join ( DIST_CLIENT_PATH , 'shared' )
8
+ export const DEFAULT_THEME_PATH = path . join ( DIST_CLIENT_PATH , 'theme-default' )
11
9
12
10
// special virtual file
13
11
// we can't directly import '/@siteData' because
Original file line number Diff line number Diff line change 5
5
createMarkdownToVueRenderFn ,
6
6
MarkdownCompileResult
7
7
} from './markdownToVue'
8
- import { APP_PATH , SITE_DATA_REQUEST_PATH } from './alias'
8
+ import { DIST_CLIENT_PATH , APP_PATH , SITE_DATA_REQUEST_PATH } from './alias'
9
9
import createVuePlugin from '@vitejs/plugin-vue'
10
10
import { slash } from './utils/slash'
11
11
import { OutputAsset , OutputChunk } from 'rollup'
@@ -87,7 +87,7 @@ export function createVitePressPlugin(
87
87
} ,
88
88
server : {
89
89
fs : {
90
- allow : [ APP_PATH , srcDir ]
90
+ allow : [ DIST_CLIENT_PATH , srcDir , process . cwd ( ) ]
91
91
}
92
92
}
93
93
} )
You can’t perform that action at this time.
0 commit comments