forked from p15670423/monkey
Add lodash minimizer. Saves roughly 50kib but for free.
This commit is contained in:
parent
aa21e864fe
commit
564f9a2cc6
File diff suppressed because it is too large
Load Diff
|
@ -26,6 +26,7 @@
|
|||
"babel-core": "^6.26.3",
|
||||
"babel-eslint": "^8.2.6",
|
||||
"babel-loader": "^7.1.5",
|
||||
"babel-plugin-lodash": "^3.3.4",
|
||||
"babel-polyfill": "^6.26.0",
|
||||
"babel-preset-env": "^1.7.0",
|
||||
"babel-preset-es2015": "^6.24.1",
|
||||
|
@ -33,11 +34,12 @@
|
|||
"babel-preset-stage-0": "^6.5.0",
|
||||
"bower-webpack-plugin": "^0.1.9",
|
||||
"chai": "^4.2.0",
|
||||
"copyfiles": "^2.1.1",
|
||||
"copyfiles": "^2.2.0",
|
||||
"css-loader": "^1.0.1",
|
||||
"duplicate-package-checker-webpack-plugin": "^3.0.0",
|
||||
"eslint": "^5.16.0",
|
||||
"eslint-loader": "^2.2.1",
|
||||
"eslint-plugin-react": "^7.16.0",
|
||||
"eslint-plugin-react": "^7.19.0",
|
||||
"file-loader": "^1.1.11",
|
||||
"glob": "^7.1.6",
|
||||
"html-loader": "^0.5.5",
|
||||
|
@ -50,19 +52,20 @@
|
|||
"karma-phantomjs-launcher": "^1.0.0",
|
||||
"karma-sourcemap-loader": "^0.3.5",
|
||||
"karma-webpack": "^3.0.5",
|
||||
"minimist": "^1.2.0",
|
||||
"lodash-webpack-plugin": "^0.11.5",
|
||||
"minimist": "^1.2.5",
|
||||
"mocha": "^5.2.0",
|
||||
"null-loader": "^0.1.1",
|
||||
"phantomjs-prebuilt": "^2.1.16",
|
||||
"react-addons-test-utils": "^15.6.2",
|
||||
"react-event-timeline": "^1.6.3",
|
||||
"react-hot-loader": "^4.12.18",
|
||||
"react-hot-loader": "^4.12.20",
|
||||
"rimraf": "^2.7.1",
|
||||
"style-loader": "^0.22.1",
|
||||
"url-loader": "^1.1.2",
|
||||
"webpack": "^4.41.2",
|
||||
"webpack-cli": "^3.3.10",
|
||||
"webpack-dev-server": "^3.9.0"
|
||||
"webpack": "^4.43.0",
|
||||
"webpack-cli": "^3.3.11",
|
||||
"webpack-dev-server": "^3.10.3"
|
||||
},
|
||||
"dependencies": {
|
||||
"@emotion/core": "^10.0.22",
|
||||
|
|
|
@ -1,4 +1,6 @@
|
|||
const path = require('path');
|
||||
const LodashModuleReplacementPlugin = require('lodash-webpack-plugin');
|
||||
const webpack = require('webpack');
|
||||
const HtmlWebPackPlugin = require("html-webpack-plugin");
|
||||
|
||||
module.exports = {
|
||||
|
@ -8,9 +10,13 @@ module.exports = {
|
|||
test: /\.js$/,
|
||||
exclude: /node_modules/,
|
||||
use: {
|
||||
loader: "babel-loader"
|
||||
loader: "babel-loader",
|
||||
options: {
|
||||
plugins: ['lodash']
|
||||
}
|
||||
},
|
||||
|
||||
},
|
||||
{
|
||||
test: /\.css$/,
|
||||
use: [
|
||||
|
@ -55,6 +61,7 @@ module.exports = {
|
|||
]
|
||||
},
|
||||
plugins: [
|
||||
new LodashModuleReplacementPlugin,
|
||||
new HtmlWebPackPlugin({
|
||||
template: "./src/index.html",
|
||||
filename: "./index.html"
|
||||
|
|
Loading…
Reference in New Issue