From 61084303890c1b5dd0757986d7ae6564fec3254e Mon Sep 17 00:00:00 2001 From: Ramon Wenger Date: Tue, 26 Jan 2021 14:26:28 +0100 Subject: [PATCH] Add todos, move config --- client/build/vue-loader.conf.js | 20 ++++++++------------ client/build/webpack.base.conf.js | 13 +++++++++++-- 2 files changed, 19 insertions(+), 14 deletions(-) diff --git a/client/build/vue-loader.conf.js b/client/build/vue-loader.conf.js index 33ed58bc..9070bcf7 100644 --- a/client/build/vue-loader.conf.js +++ b/client/build/vue-loader.conf.js @@ -7,16 +7,12 @@ const sourceMapEnabled = isProduction : config.dev.cssSourceMap module.exports = { - loaders: utils.cssLoaders({ - sourceMap: sourceMapEnabled, - extract: isProduction - }), - cssSourceMap: sourceMapEnabled, - cacheBusting: config.dev.cacheBusting, - transformToRequire: { - video: ['src', 'poster'], - source: 'src', - img: 'src', - image: 'xlink:href' - } + // loaders: utils.cssLoaders({ + // sourceMap: sourceMapEnabled, + // todo: need that? + // extract: isProduction + // }), + // cssSourceMap: sourceMapEnabled, + // cacheBusting: config.dev.cacheBusting, + } diff --git a/client/build/webpack.base.conf.js b/client/build/webpack.base.conf.js index 9243ce6a..a2c932e6 100644 --- a/client/build/webpack.base.conf.js +++ b/client/build/webpack.base.conf.js @@ -6,7 +6,7 @@ const vueLoaderConfig = require('./vue-loader.conf') const VueLoaderPlugin = require('vue-loader/lib/plugin') -function resolve (dir) { +function resolve(dir) { return path.join(__dirname, '..', dir) } @@ -21,6 +21,8 @@ const createLintingRule = () => ({ } }) +//todo on monday: mini-css-extract-plugin? +//https://github.com/webpack-contrib/mini-css-extract-plugin //todo: do we need postcss? module.exports = { context: path.resolve(__dirname, '../'), @@ -47,7 +49,14 @@ module.exports = { { test: /\.vue$/, loader: 'vue-loader', - options: vueLoaderConfig + options: { + transformAssetUrls: { + video: ['src', 'poster'], + source: 'src', + img: 'src', + image: 'xlink:href' + } + } }, { test: /\.js$/,