From 8318ce75101d707b7a9d30a059387ded72bed629 Mon Sep 17 00:00:00 2001 From: Atinux Date: Tue, 31 Oct 2017 18:33:25 +0100 Subject: [PATCH] fix: loadResources after every build --- lib/builder/builder.js | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/lib/builder/builder.js b/lib/builder/builder.js index 1dbef90a59..b5a51aee9b 100644 --- a/lib/builder/builder.js +++ b/lib/builder/builder.js @@ -435,6 +435,9 @@ export default class Builder { // Resolve only when compiler emit done event compiler.plugin('done', async (stats) => { await this.nuxt.callHook('build:compiled', { name, compiler, stats }) + // Reload renderer if available + this.nuxt.renderer.loadResources(sharedFS || fs) + // Resolve on next tick process.nextTick(resolve) }) // --- Dev Build --- @@ -475,10 +478,6 @@ export default class Builder { } }) })) - // Reload renderer if available - if (this.nuxt.renderer) { - this.nuxt.renderer.loadResources(sharedFS || fs) - } } webpackDev(compiler) {