diff options
Diffstat (limited to 'client/webpack')
-rw-r--r-- | client/webpack/webpack.video-embed.js | 44 |
1 files changed, 22 insertions, 22 deletions
diff --git a/client/webpack/webpack.video-embed.js b/client/webpack/webpack.video-embed.js index aa7c5e550..b20a21872 100644 --- a/client/webpack/webpack.video-embed.js +++ b/client/webpack/webpack.video-embed.js | |||
@@ -4,8 +4,8 @@ const path = require('path') | |||
4 | const HtmlWebpackPlugin = require('html-webpack-plugin') | 4 | const HtmlWebpackPlugin = require('html-webpack-plugin') |
5 | const TerserPlugin = require('terser-webpack-plugin') | 5 | const TerserPlugin = require('terser-webpack-plugin') |
6 | const LoaderOptionsPlugin = require('webpack/lib/LoaderOptionsPlugin') | 6 | const LoaderOptionsPlugin = require('webpack/lib/LoaderOptionsPlugin') |
7 | const ExtractTextPlugin = require('extract-text-webpack-plugin') | ||
8 | const PurifyCSSPlugin = require('purifycss-webpack') | 7 | const PurifyCSSPlugin = require('purifycss-webpack') |
8 | const MiniCssExtractPlugin = require('mini-css-extract-plugin') | ||
9 | 9 | ||
10 | module.exports = function () { | 10 | module.exports = function () { |
11 | const configuration = { | 11 | const configuration = { |
@@ -64,29 +64,29 @@ module.exports = function () { | |||
64 | 64 | ||
65 | { | 65 | { |
66 | test: /\.(sass|scss)$/, | 66 | test: /\.(sass|scss)$/, |
67 | use: ExtractTextPlugin.extract({ | 67 | use: [ |
68 | fallback: 'style-loader', | 68 | MiniCssExtractPlugin.loader, |
69 | use: [ | 69 | |
70 | { | 70 | { |
71 | loader: 'css-loader', | 71 | loader: 'css-loader', |
72 | options: { | 72 | options: { |
73 | sourceMap: true, | ||
74 | importLoaders: 1 | ||
75 | } | ||
76 | }, | ||
77 | |||
78 | { | ||
79 | loader: 'sass-loader', | ||
80 | options: { | ||
81 | sassOptions: { | ||
73 | sourceMap: true, | 82 | sourceMap: true, |
74 | importLoaders: 1 | 83 | includePaths: [ |
75 | } | 84 | helpers.root('src/sass/include') |
76 | }, | 85 | ] |
77 | { | ||
78 | loader: 'sass-loader', | ||
79 | options: { | ||
80 | sassOptions: { | ||
81 | sourceMap: true, | ||
82 | includePaths: [ | ||
83 | helpers.root('src/sass/include') | ||
84 | ] | ||
85 | } | ||
86 | } | 86 | } |
87 | } | 87 | } |
88 | ] | 88 | } |
89 | }) | 89 | ] |
90 | }, | 90 | }, |
91 | 91 | ||
92 | { | 92 | { |
@@ -111,7 +111,7 @@ module.exports = function () { | |||
111 | }, | 111 | }, |
112 | 112 | ||
113 | plugins: [ | 113 | plugins: [ |
114 | new ExtractTextPlugin({ | 114 | new MiniCssExtractPlugin({ |
115 | filename: process.env.ANALYZE_BUNDLE === 'true' | 115 | filename: process.env.ANALYZE_BUNDLE === 'true' |
116 | ? '[name].css' | 116 | ? '[name].css' |
117 | : '[name].[hash].css' | 117 | : '[name].[hash].css' |