From e7bcdc736ea5dec8746dbdfa217dee609a460a73 Mon Sep 17 00:00:00 2001 From: Walter Ye Date: Sat, 1 Apr 2017 13:34:09 +0800 Subject: [PATCH] pass 'this nuxt' context in extend webpack config // nuxt.config build: { extend (config, {dev, isClient}) { // get this context here config.resolve.alias['~services'] = join(this.srcDir, 'services'); }, } --- lib/webpack/client.config.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/webpack/client.config.js b/lib/webpack/client.config.js index 75a69cbf54..068a5c20dd 100644 --- a/lib/webpack/client.config.js +++ b/lib/webpack/client.config.js @@ -105,7 +105,7 @@ export default function () { } // Extend config if (typeof this.options.build.extend === 'function') { - this.options.build.extend(config, { + this.options.build.extend.call(this, config, { dev: this.dev, isClient: true })