From 0558ae261e483c51bb2310853f2cf844bb264669 Mon Sep 17 00:00:00 2001 From: Clark Du Date: Tue, 28 Nov 2017 11:27:17 +0800 Subject: [PATCH] fix: vuetify includes es modules --- examples/with-vuetify/nuxt.config.js | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/examples/with-vuetify/nuxt.config.js b/examples/with-vuetify/nuxt.config.js index df74955493..a3b50d43bf 100644 --- a/examples/with-vuetify/nuxt.config.js +++ b/examples/with-vuetify/nuxt.config.js @@ -1,3 +1,5 @@ +const nodeExternals = require('webpack-node-externals') + module.exports = { /* ** Head elements @@ -13,7 +15,16 @@ module.exports = { */ build: { vendor: ['vuetify'], - extractCSS: true + extractCSS: true, + extend(config, ctx) { + if (ctx.isServer) { + config.externals = [ + nodeExternals({ + whitelist: [/^vuetify/] + }) + ] + } + } }, /* ** Load Vuetify into the app