Bring back extract text webpack plugin
This commit is contained in:
parent
f9ec9d7b15
commit
9808c1cdf5
|
@ -96,6 +96,7 @@
|
||||||
"eslint-plugin-prettier": "^2.0.1",
|
"eslint-plugin-prettier": "^2.0.1",
|
||||||
"eslint-plugin-react": "^6.10.3",
|
"eslint-plugin-react": "^6.10.3",
|
||||||
"exports-loader": "0.6.3",
|
"exports-loader": "0.6.3",
|
||||||
|
"extract-text-webpack-plugin": "1.0.1",
|
||||||
"fbemitter": "^2.1.1",
|
"fbemitter": "^2.1.1",
|
||||||
"file-loader": "0.9.0",
|
"file-loader": "0.9.0",
|
||||||
"flow-typed": "^2.1.2",
|
"flow-typed": "^2.1.2",
|
||||||
|
|
|
@ -1,6 +1,7 @@
|
||||||
/* eslint-disable */
|
/* eslint-disable */
|
||||||
var webpack = require('webpack');
|
var webpack = require('webpack');
|
||||||
var HtmlWebpackPlugin = require('html-webpack-plugin');
|
var HtmlWebpackPlugin = require('html-webpack-plugin');
|
||||||
|
var ExtractTextPlugin = require('extract-text-webpack-plugin');
|
||||||
|
|
||||||
const commonWebpackConfig = require('./webpack.config');
|
const commonWebpackConfig = require('./webpack.config');
|
||||||
|
|
||||||
|
@ -18,6 +19,7 @@ const developmentWebpackConfig = Object.assign(commonWebpackConfig, {
|
||||||
developmentWebpackConfig.plugins.push(
|
developmentWebpackConfig.plugins.push(
|
||||||
new webpack.optimize.OccurenceOrderPlugin()
|
new webpack.optimize.OccurenceOrderPlugin()
|
||||||
);
|
);
|
||||||
|
developmentWebpackConfig.plugins.push(new ExtractTextPlugin('styles.css'));
|
||||||
developmentWebpackConfig.plugins.push(new webpack.HotModuleReplacementPlugin());
|
developmentWebpackConfig.plugins.push(new webpack.HotModuleReplacementPlugin());
|
||||||
developmentWebpackConfig.plugins.push(new webpack.NoErrorsPlugin());
|
developmentWebpackConfig.plugins.push(new webpack.NoErrorsPlugin());
|
||||||
developmentWebpackConfig.plugins.push(
|
developmentWebpackConfig.plugins.push(
|
||||||
|
|
|
@ -1,6 +1,7 @@
|
||||||
/* eslint-disable */
|
/* eslint-disable */
|
||||||
const path = require('path');
|
const path = require('path');
|
||||||
const webpack = require('webpack');
|
const webpack = require('webpack');
|
||||||
|
var ExtractTextPlugin = require('extract-text-webpack-plugin');
|
||||||
|
|
||||||
require('dotenv').config({ silent: true });
|
require('dotenv').config({ silent: true });
|
||||||
|
|
||||||
|
@ -40,7 +41,7 @@ module.exports = {
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
test: /\.css$/,
|
test: /\.css$/,
|
||||||
loader: 'style-loader!css-loader?sourceMap',
|
loader: ExtractTextPlugin.extract('style-loader', 'css-loader'),
|
||||||
},
|
},
|
||||||
{ test: /\.md/, loader: 'raw-loader' },
|
{ test: /\.md/, loader: 'raw-loader' },
|
||||||
],
|
],
|
||||||
|
|
|
@ -20,6 +20,9 @@ productionWebpackConfig.plugins.push(
|
||||||
template: 'server/static/index.html',
|
template: 'server/static/index.html',
|
||||||
})
|
})
|
||||||
);
|
);
|
||||||
|
productionWebpackConfig.plugins.push(
|
||||||
|
new ExtractTextPlugin('styles.[hash].css')
|
||||||
|
);
|
||||||
productionWebpackConfig.plugins.push(
|
productionWebpackConfig.plugins.push(
|
||||||
new webpack.optimize.OccurenceOrderPlugin()
|
new webpack.optimize.OccurenceOrderPlugin()
|
||||||
);
|
);
|
||||||
|
|
21
yarn.lock
21
yarn.lock
|
@ -306,7 +306,7 @@ async@^0.9.0:
|
||||||
version "0.9.2"
|
version "0.9.2"
|
||||||
resolved "https://registry.yarnpkg.com/async/-/async-0.9.2.tgz#aea74d5e61c1f899613bf64bda66d4c78f2fd17d"
|
resolved "https://registry.yarnpkg.com/async/-/async-0.9.2.tgz#aea74d5e61c1f899613bf64bda66d4c78f2fd17d"
|
||||||
|
|
||||||
async@^1.3.0, async@^1.4.0:
|
async@^1.3.0, async@^1.4.0, async@^1.5.0:
|
||||||
version "1.5.2"
|
version "1.5.2"
|
||||||
resolved "https://registry.yarnpkg.com/async/-/async-1.5.2.tgz#ec6a61ae56480c0c3cb241c95618e20892f9672a"
|
resolved "https://registry.yarnpkg.com/async/-/async-1.5.2.tgz#ec6a61ae56480c0c3cb241c95618e20892f9672a"
|
||||||
|
|
||||||
|
@ -3035,6 +3035,14 @@ extglob@^0.3.1:
|
||||||
dependencies:
|
dependencies:
|
||||||
is-extglob "^1.0.0"
|
is-extglob "^1.0.0"
|
||||||
|
|
||||||
|
extract-text-webpack-plugin@1.0.1:
|
||||||
|
version "1.0.1"
|
||||||
|
resolved "https://registry.yarnpkg.com/extract-text-webpack-plugin/-/extract-text-webpack-plugin-1.0.1.tgz#c95bf3cbaac49dc96f1dc6e072549fbb654ccd2c"
|
||||||
|
dependencies:
|
||||||
|
async "^1.5.0"
|
||||||
|
loader-utils "^0.2.3"
|
||||||
|
webpack-sources "^0.1.0"
|
||||||
|
|
||||||
extsprintf@1.3.0, extsprintf@^1.2.0:
|
extsprintf@1.3.0, extsprintf@^1.2.0:
|
||||||
version "1.3.0"
|
version "1.3.0"
|
||||||
resolved "https://registry.yarnpkg.com/extsprintf/-/extsprintf-1.3.0.tgz#96918440e3041a7a414f8c52e3c574eb3c3e1e05"
|
resolved "https://registry.yarnpkg.com/extsprintf/-/extsprintf-1.3.0.tgz#96918440e3041a7a414f8c52e3c574eb3c3e1e05"
|
||||||
|
@ -5298,7 +5306,7 @@ load-json-file@^2.0.0:
|
||||||
pify "^2.0.0"
|
pify "^2.0.0"
|
||||||
strip-bom "^3.0.0"
|
strip-bom "^3.0.0"
|
||||||
|
|
||||||
loader-utils@0.2.x, loader-utils@^0.2.11, loader-utils@^0.2.14, loader-utils@~0.2.5:
|
loader-utils@0.2.x, loader-utils@^0.2.11, loader-utils@^0.2.14, loader-utils@^0.2.3, loader-utils@~0.2.5:
|
||||||
version "0.2.17"
|
version "0.2.17"
|
||||||
resolved "https://registry.yarnpkg.com/loader-utils/-/loader-utils-0.2.17.tgz#f86e6374d43205a6e6c60e9196f17c0299bfb348"
|
resolved "https://registry.yarnpkg.com/loader-utils/-/loader-utils-0.2.17.tgz#f86e6374d43205a6e6c60e9196f17c0299bfb348"
|
||||||
dependencies:
|
dependencies:
|
||||||
|
@ -8190,7 +8198,7 @@ source-map@0.5.6:
|
||||||
version "0.5.6"
|
version "0.5.6"
|
||||||
resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.5.6.tgz#75ce38f52bf0733c5a7f0c118d81334a2bb5f412"
|
resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.5.6.tgz#75ce38f52bf0733c5a7f0c118d81334a2bb5f412"
|
||||||
|
|
||||||
source-map@^0.5.3, source-map@^0.5.6, source-map@^0.5.7, source-map@~0.5.0, source-map@~0.5.1:
|
source-map@^0.5.3, source-map@^0.5.6, source-map@^0.5.7, source-map@~0.5.0, source-map@~0.5.1, source-map@~0.5.3:
|
||||||
version "0.5.7"
|
version "0.5.7"
|
||||||
resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.5.7.tgz#8a039d2d1021d22d1ea14c80d8ea468ba2ef3fcc"
|
resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.5.7.tgz#8a039d2d1021d22d1ea14c80d8ea468ba2ef3fcc"
|
||||||
|
|
||||||
|
@ -9100,6 +9108,13 @@ webpack-hot-middleware@2.x:
|
||||||
querystring "^0.2.0"
|
querystring "^0.2.0"
|
||||||
strip-ansi "^3.0.0"
|
strip-ansi "^3.0.0"
|
||||||
|
|
||||||
|
webpack-sources@^0.1.0:
|
||||||
|
version "0.1.5"
|
||||||
|
resolved "https://registry.yarnpkg.com/webpack-sources/-/webpack-sources-0.1.5.tgz#aa1f3abf0f0d74db7111c40e500b84f966640750"
|
||||||
|
dependencies:
|
||||||
|
source-list-map "~0.1.7"
|
||||||
|
source-map "~0.5.3"
|
||||||
|
|
||||||
webpack@1.13.2:
|
webpack@1.13.2:
|
||||||
version "1.13.2"
|
version "1.13.2"
|
||||||
resolved "https://registry.yarnpkg.com/webpack/-/webpack-1.13.2.tgz#f11a96f458eb752970a86abe746c0704fabafaf3"
|
resolved "https://registry.yarnpkg.com/webpack/-/webpack-1.13.2.tgz#f11a96f458eb752970a86abe746c0704fabafaf3"
|
||||||
|
|
Reference in New Issue