File tree 1 file changed +8
-4
lines changed
packages/@vuepress/core/lib/node
1 file changed +8
-4
lines changed Original file line number Diff line number Diff line change @@ -46,10 +46,6 @@ module.exports = class App {
46
46
logger . warn ( `Source directory doesn't exist: ${ chalk . yellow ( this . sourceDir ) } ` )
47
47
}
48
48
49
- const { tempPath, writeTemp } = createTemp ( options . temp )
50
- this . tempPath = tempPath
51
- this . writeTemp = writeTemp
52
-
53
49
this . vuepressDir = path . resolve ( this . sourceDir , '.vuepress' )
54
50
this . libDir = path . join ( __dirname , '../' )
55
51
}
@@ -78,10 +74,18 @@ module.exports = class App {
78
74
this . base = this . siteConfig . base || '/'
79
75
this . themeConfig = this . siteConfig . themeConfig || { }
80
76
77
+ // resolve tempPath
78
+ const rawTemp = this . options . temp || this . siteConfig . temp
79
+ const { tempPath, writeTemp } = createTemp ( rawTemp )
80
+ this . tempPath = tempPath
81
+ this . writeTemp = writeTemp
82
+
83
+ // resolve outDir
81
84
const rawOutDir = this . options . dest || this . siteConfig . dest
82
85
this . outDir = rawOutDir
83
86
? require ( 'path' ) . resolve ( this . cwd , rawOutDir )
84
87
: require ( 'path' ) . resolve ( this . sourceDir , '.vuepress/dist' )
88
+
85
89
this . pages = [ ] // Array<Page>
86
90
this . pluginAPI = new PluginAPI ( this )
87
91
this . ClientComputedMixinConstructor = ClientComputedMixin ( this . getSiteData ( ) )
You can’t perform that action at this time.
0 commit comments