diff options
author | Chocobozzz <florian.bigard@gmail.com> | 2017-12-11 11:06:32 +0100 |
---|---|---|
committer | Chocobozzz <florian.bigard@gmail.com> | 2017-12-11 11:06:32 +0100 |
commit | fada8d75550dc7365f7e18ee1569b9406251d660 (patch) | |
tree | db9dc01c18693824f83fce5020f4c1f3ae7c0865 /client/config/webpack.common.js | |
parent | 492fd28167f770d79a430fc57451b5a9e075d8e7 (diff) | |
parent | c2830fa8f84f61462098bf36add824f89436dfa9 (diff) | |
download | PeerTube-fada8d75550dc7365f7e18ee1569b9406251d660.tar.gz PeerTube-fada8d75550dc7365f7e18ee1569b9406251d660.tar.zst PeerTube-fada8d75550dc7365f7e18ee1569b9406251d660.zip |
Merge branch 'feature/design' into develop
Diffstat (limited to 'client/config/webpack.common.js')
-rw-r--r-- | client/config/webpack.common.js | 18 |
1 files changed, 16 insertions, 2 deletions
diff --git a/client/config/webpack.common.js b/client/config/webpack.common.js index 9cd33d2ed..f387b44f9 100644 --- a/client/config/webpack.common.js +++ b/client/config/webpack.common.js | |||
@@ -13,6 +13,7 @@ const LoaderOptionsPlugin = require('webpack/lib/LoaderOptionsPlugin') | |||
13 | const ScriptExtHtmlWebpackPlugin = require('script-ext-html-webpack-plugin') | 13 | const ScriptExtHtmlWebpackPlugin = require('script-ext-html-webpack-plugin') |
14 | const InlineManifestWebpackPlugin = require('inline-manifest-webpack-plugin') | 14 | const InlineManifestWebpackPlugin = require('inline-manifest-webpack-plugin') |
15 | const ngcWebpack = require('ngc-webpack') | 15 | const ngcWebpack = require('ngc-webpack') |
16 | const CopyWebpackPlugin = require('copy-webpack-plugin') | ||
16 | 17 | ||
17 | const WebpackNotifierPlugin = require('webpack-notifier') | 18 | const WebpackNotifierPlugin = require('webpack-notifier') |
18 | 19 | ||
@@ -146,14 +147,15 @@ module.exports = function (options) { | |||
146 | loader: 'sass-resources-loader', | 147 | loader: 'sass-resources-loader', |
147 | options: { | 148 | options: { |
148 | resources: [ | 149 | resources: [ |
149 | helpers.root('src/sass/_variables.scss') | 150 | helpers.root('src/sass/_variables.scss'), |
151 | helpers.root('src/sass/_mixins.scss') | ||
150 | ] | 152 | ] |
151 | } | 153 | } |
152 | } | 154 | } |
153 | ] | 155 | ] |
154 | }, | 156 | }, |
155 | { test: /\.woff(2)?(\?v=[0-9]\.[0-9]\.[0-9])?$/, use: 'url-loader?limit=10000&minetype=application/font-woff' }, | 157 | { test: /\.woff(2)?(\?v=[0-9]\.[0-9]\.[0-9])?$/, use: 'url-loader?limit=10000&minetype=application/font-woff' }, |
156 | { test: /\.(ttf|eot|svg)(\?v=[0-9]\.[0-9]\.[0-9])?$/, use: 'file-loader' }, | 158 | { test: /\.(otf|ttf|eot|svg)(\?v=[0-9]\.[0-9]\.[0-9])?$/, use: 'url-loader?limit=10000' }, |
157 | 159 | ||
158 | /* Raw loader support for *.html | 160 | /* Raw loader support for *.html |
159 | * Returns file content as string | 161 | * Returns file content as string |
@@ -266,6 +268,17 @@ module.exports = function (options) { | |||
266 | inject: 'body' | 268 | inject: 'body' |
267 | }), | 269 | }), |
268 | 270 | ||
271 | new CopyWebpackPlugin([ | ||
272 | { | ||
273 | from: helpers.root('src/assets/images/favicon.png'), | ||
274 | to: 'assets/images/favicon.png' | ||
275 | }, | ||
276 | { | ||
277 | from: helpers.root('src/assets/images/default-avatar.png'), | ||
278 | to: 'assets/images/default-avatar.png' | ||
279 | } | ||
280 | ]), | ||
281 | |||
269 | /* | 282 | /* |
270 | * Plugin: ScriptExtHtmlWebpackPlugin | 283 | * Plugin: ScriptExtHtmlWebpackPlugin |
271 | * Description: Enhances html-webpack-plugin functionality | 284 | * Description: Enhances html-webpack-plugin functionality |
@@ -289,6 +302,7 @@ module.exports = function (options) { | |||
289 | */ | 302 | */ |
290 | new LoaderOptionsPlugin({ | 303 | new LoaderOptionsPlugin({ |
291 | options: { | 304 | options: { |
305 | context: '', | ||
292 | sassLoader: { | 306 | sassLoader: { |
293 | precision: 10, | 307 | precision: 10, |
294 | includePaths: [ helpers.root('src/sass') ] | 308 | includePaths: [ helpers.root('src/sass') ] |