mirror of
https://github.com/nuxt/nuxt.git
synced 2024-11-30 01:17:16 +00:00
Join with this.dir if relative path
This commit is contained in:
parent
187fec3f32
commit
6713f68443
@ -51,7 +51,7 @@ class Nuxt {
|
|||||||
// Env variables
|
// Env variables
|
||||||
this.dev = this.options.dev
|
this.dev = this.options.dev
|
||||||
this.dir = (typeof options.rootDir === 'string' && options.rootDir ? options.rootDir : process.cwd())
|
this.dir = (typeof options.rootDir === 'string' && options.rootDir ? options.rootDir : process.cwd())
|
||||||
this.srcDir = (typeof options.srcDir === 'string' && options.srcDir ? options.srcDir : this.dir)
|
this.srcDir = (typeof options.srcDir === 'string' && options.srcDir ? resolve(this.dir, options.srcDir) : this.dir)
|
||||||
// If store defined, update store options to true
|
// If store defined, update store options to true
|
||||||
if (fs.existsSync(join(this.srcDir, 'store', 'index.js'))) {
|
if (fs.existsSync(join(this.srcDir, 'store', 'index.js'))) {
|
||||||
this.options.store = true
|
this.options.store = true
|
||||||
|
Loading…
Reference in New Issue
Block a user