mirror of
https://github.com/captbaritone/webamp.git
synced 2026-07-22 09:37:17 +00:00
30 lines
772 B
JavaScript
30 lines
772 B
JavaScript
const webpack = require("webpack");
|
|
const merge = require("webpack-merge");
|
|
const workboxPlugin = require("workbox-webpack-plugin");
|
|
const common = require("./webpack.common.js");
|
|
|
|
const config = merge(common, {
|
|
devtool: "source-map",
|
|
plugins: [
|
|
new webpack.DefinePlugin({
|
|
"process.env": {
|
|
NODE_ENV: JSON.stringify("production")
|
|
},
|
|
SENTRY_DSN: JSON.stringify(
|
|
"https://12b6be8ef7c44f28ac37ab5ed98fd294@sentry.io/146021"
|
|
)
|
|
}),
|
|
new webpack.optimize.UglifyJsPlugin({
|
|
sourceMap: true
|
|
}),
|
|
new workboxPlugin.GenerateSW({
|
|
swDest: "service-worker.js",
|
|
clientsClaim: true,
|
|
skipWaiting: true
|
|
})
|
|
]
|
|
});
|
|
|
|
config.entry.winamp.unshift("./js/googleAnalytics.min.js");
|
|
|
|
module.exports = config;
|