#101 Minified JS files

master
Keith Irwin 2017-07-21 09:17:06 -04:00
parent 6af4beb237
commit 780b64943b
No known key found for this signature in database
GPG Key ID: 378933C743E2BBC0
4 changed files with 2402 additions and 408 deletions

2788
package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@ -33,6 +33,7 @@
"socket.io": "^2.0.3", "socket.io": "^2.0.3",
"socket.io-client": "^2.0.3", "socket.io-client": "^2.0.3",
"style-loader": "^0.18.2", "style-loader": "^0.18.2",
"uglifyjs-webpack-plugin": "^0.4.6",
"webpack": "^3.0.0", "webpack": "^3.0.0",
"xss": "^0.3.3", "xss": "^0.3.3",
"zxcvbn": "^4.4.2" "zxcvbn": "^4.4.2"

View File

@ -53,7 +53,7 @@ $(function() {
// Load google maps // Load google maps
loadGoogleMapsAPI({ key:mapKey }) loadGoogleMapsAPI({ key:mapKey })
.then(function(googlemaps) { .then( function(googlemaps) {
// Create map // Create map
if (disp!=='1') { if (disp!=='1') {
@ -293,6 +293,6 @@ loadGoogleMapsAPI({ key:mapKey })
} }
}).catch((err) => { }).catch( function(err) {
console.error(err); console.error(err);
}); });

View File

@ -1,5 +1,5 @@
const path = require('path'), const path = require('path'),
webpack = require('webpack'); uglifyJsPlugin = require('uglifyjs-webpack-plugin');
module.exports = { module.exports = {
@ -25,18 +25,23 @@ module.exports = {
path: path.resolve(__dirname, 'static/js') path: path.resolve(__dirname, 'static/js')
}, },
// Optimization plugins: [
// plugins: [
// new webpack.optimize.UglifyJsPlugin({minimize: true}) // Minimize JS
// ], new uglifyJsPlugin()
],
// Load CSS into bundles
module: { module: {
rules: [ rules: [
// Load CSS into bundles
{ {
test: /\.css$/, test: /\.css$/,
use: [ 'style-loader', 'css-loader' ] use: [ 'style-loader', 'css-loader' ]
} }
] ]
} }