diff options
author | Chocobozzz <florian.bigard@gmail.com> | 2016-09-19 22:09:12 +0200 |
---|---|---|
committer | Chocobozzz <florian.bigard@gmail.com> | 2016-09-19 22:09:12 +0200 |
commit | d268c551cc0cbe2f83f8cc9533ce5f636eda860a (patch) | |
tree | 29c53c0e693689bae73007ae8fe13d456f3b0547 /client/config | |
parent | d3cd34be2fd03ea79145dfa8eb16e82d2e23191b (diff) | |
download | PeerTube-d268c551cc0cbe2f83f8cc9533ce5f636eda860a.tar.gz PeerTube-d268c551cc0cbe2f83f8cc9533ce5f636eda860a.tar.zst PeerTube-d268c551cc0cbe2f83f8cc9533ce5f636eda860a.zip |
Client: update to angular 2.0
Diffstat (limited to 'client/config')
-rw-r--r-- | client/config/webpack.common.js | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/client/config/webpack.common.js b/client/config/webpack.common.js index 2ce44b6c7..88a3639d2 100644 --- a/client/config/webpack.common.js +++ b/client/config/webpack.common.js | |||
@@ -9,6 +9,7 @@ const CopyWebpackPlugin = require('copy-webpack-plugin') | |||
9 | const HtmlWebpackPlugin = require('html-webpack-plugin') | 9 | const HtmlWebpackPlugin = require('html-webpack-plugin') |
10 | const ForkCheckerPlugin = require('awesome-typescript-loader').ForkCheckerPlugin | 10 | const ForkCheckerPlugin = require('awesome-typescript-loader').ForkCheckerPlugin |
11 | const AssetsPlugin = require('assets-webpack-plugin') | 11 | const AssetsPlugin = require('assets-webpack-plugin') |
12 | const ContextReplacementPlugin = require('webpack/lib/ContextReplacementPlugin') | ||
12 | const WebpackNotifierPlugin = require('webpack-notifier') | 13 | const WebpackNotifierPlugin = require('webpack-notifier') |
13 | 14 | ||
14 | /* | 15 | /* |
@@ -202,6 +203,19 @@ module.exports = function (options) { | |||
202 | name: [ 'polyfills', 'vendor' ].reverse() | 203 | name: [ 'polyfills', 'vendor' ].reverse() |
203 | }), | 204 | }), |
204 | 205 | ||
206 | /** | ||
207 | * Plugin: ContextReplacementPlugin | ||
208 | * Description: Provides context to Angular's use of System.import | ||
209 | * | ||
210 | * See: https://webpack.github.io/docs/list-of-plugins.html#contextreplacementplugin | ||
211 | * See: https://github.com/angular/angular/issues/11580 | ||
212 | */ | ||
213 | new ContextReplacementPlugin( | ||
214 | // The (\\|\/) piece accounts for path separators in *nix and Windows | ||
215 | /angular(\\|\/)core(\\|\/)(esm(\\|\/)src|src)(\\|\/)linker/, | ||
216 | helpers.root('src') // location of your src | ||
217 | ), | ||
218 | |||
205 | /* | 219 | /* |
206 | * Plugin: CopyWebpackPlugin | 220 | * Plugin: CopyWebpackPlugin |
207 | * Description: Copy files and directories in webpack. | 221 | * Description: Copy files and directories in webpack. |