From 3a5660ce1e6d404bd09e997dee68959b8d3855f2 Mon Sep 17 00:00:00 2001 From: Sam Carlton Date: Sat, 4 Sep 2021 16:06:56 -0500 Subject: [PATCH] Use webpack-import-meta-loader for all contexts --- nuxt.config.js | 20 +++++++++++++------- 1 file changed, 13 insertions(+), 7 deletions(-) diff --git a/nuxt.config.js b/nuxt.config.js index 5b8fe7a..90c7792 100644 --- a/nuxt.config.js +++ b/nuxt.config.js @@ -163,14 +163,20 @@ export default { */ extend(config, ctx) { + + // Always run + + // Push meta import rule for zip.js + config.module.rules.push({ + test: /\.js$/, + loader: require.resolve('@open-wc/webpack-import-meta-loader') + }) + + + // Client - if (ctx.isClient) { - // Push meta import rule for zip.js - config.module.rules.push({ - test: /\.js$/, - loader: require.resolve('@open-wc/webpack-import-meta-loader') - }) - } + // if (ctx.isClient) { + // } // Run ESLint on save if (ctx.isDev && ctx.isClient) {