diff --git a/lib/builder/generator.js b/lib/builder/generator.js index 5845b17049..f2548a6c18 100644 --- a/lib/builder/generator.js +++ b/lib/builder/generator.js @@ -26,12 +26,14 @@ export default class Generator extends Tapable { const s = Date.now() let errors = [] + // Add flag to set process.generate + this.builder.forGenerate() + // Wait for nuxt be ready await this.nuxt.ready() // Start build process if (build) { - this.builder.forGenerate() // Add flag to set process.generate await this.builder.build() }