2020-06-17 10:44:59 +00:00
|
|
|
const webpack = require('webpack');
|
2020-07-15 08:00:17 +00:00
|
|
|
const WebpackAssetsManifest = require('webpack-assets-manifest');
|
2020-06-17 10:44:59 +00:00
|
|
|
|
|
|
|
module.exports = {
|
|
|
|
mode: 'production',
|
|
|
|
entry: {
|
|
|
|
VueTranslations: './vue/VueTranslations.js',
|
|
|
|
InlinePlayer: './vue/InlinePlayer.vue',
|
2021-03-16 12:25:29 +00:00
|
|
|
Dashboard: './vue/Dashboard.vue',
|
|
|
|
AdminStorageLocations: './vue/Admin/StorageLocations.vue',
|
|
|
|
PublicFullPlayer: './vue/Public/FullPlayer.vue',
|
2021-03-17 07:20:12 +00:00
|
|
|
PublicHistory: './vue/Public/History.vue',
|
2021-03-16 12:25:29 +00:00
|
|
|
PublicOnDemand: './vue/Public/OnDemand.vue',
|
|
|
|
PublicPlayer: './vue/Public/Player.vue',
|
|
|
|
PublicRequests: './vue/Public/Requests.vue',
|
2021-06-21 01:58:02 +00:00
|
|
|
PublicSchedule: './vue/Public/Schedule.vue',
|
2021-03-16 12:25:29 +00:00
|
|
|
PublicWebDJ: './vue/Public/WebDJ.vue',
|
|
|
|
StationsMedia: './vue/Stations/Media.vue',
|
2021-06-12 07:04:27 +00:00
|
|
|
StationsMounts: './vue/Stations/Mounts.vue',
|
2021-03-16 12:25:29 +00:00
|
|
|
StationsPlaylists: './vue/Stations/Playlists.vue',
|
2021-05-25 04:29:07 +00:00
|
|
|
StationsPodcasts: './vue/Stations/Podcasts.vue',
|
2021-03-16 12:25:29 +00:00
|
|
|
StationsProfile: './vue/Stations/Profile.vue',
|
|
|
|
StationsQueue: './vue/Stations/Queue.vue',
|
2021-05-03 15:40:21 +00:00
|
|
|
StationsStreamers: './vue/Stations/Streamers.vue',
|
|
|
|
StationsReportsOverview: './vue/Stations/Reports/Overview.vue'
|
2020-06-17 10:44:59 +00:00
|
|
|
},
|
|
|
|
resolve: {
|
|
|
|
extensions: ['*', '.js', '.vue', '.json']
|
|
|
|
},
|
|
|
|
output: {
|
2020-07-15 08:00:17 +00:00
|
|
|
publicPath: 'dist/',
|
2020-06-17 10:44:59 +00:00
|
|
|
filename: '[name].js',
|
|
|
|
sourceMapFilename: '[name].map',
|
|
|
|
library: '[name]'
|
|
|
|
},
|
|
|
|
optimization: {
|
|
|
|
splitChunks: {
|
|
|
|
cacheGroups: {
|
2020-07-15 08:00:17 +00:00
|
|
|
moment: {
|
|
|
|
test: /[\\/]node_modules[\\/]moment/,
|
|
|
|
name: 'vendor-moment',
|
|
|
|
priority: 2,
|
|
|
|
chunks: 'initial',
|
|
|
|
enforce: true
|
|
|
|
},
|
|
|
|
fullcalendar: {
|
|
|
|
test: /[\\/]node_modules[\\/]@fullcalendar/,
|
|
|
|
name: 'vendor-fullcalendar',
|
|
|
|
priority: 2,
|
2020-06-17 10:44:59 +00:00
|
|
|
chunks: 'initial',
|
2020-07-15 08:00:17 +00:00
|
|
|
enforce: true
|
|
|
|
},
|
|
|
|
vendor: {
|
|
|
|
test: /[\\/]node_modules[\\/]/,
|
2020-06-17 10:44:59 +00:00
|
|
|
name: 'vendor',
|
2020-07-15 08:00:17 +00:00
|
|
|
chunks: 'initial',
|
2020-06-17 10:44:59 +00:00
|
|
|
enforce: true
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
|
|
|
module: {
|
|
|
|
rules: [
|
|
|
|
{
|
|
|
|
test: /\.vue$/,
|
|
|
|
loader: 'vue-loader',
|
|
|
|
},
|
|
|
|
{
|
|
|
|
test: /\.scss$/,
|
2021-04-29 09:24:11 +00:00
|
|
|
loader: 'vue-style-loader'
|
2020-06-17 10:44:59 +00:00
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
plugins: [
|
2020-07-15 08:00:17 +00:00
|
|
|
new WebpackAssetsManifest({
|
|
|
|
output: '../web/static/webpack.json',
|
|
|
|
writeToDisk: true,
|
|
|
|
merge: true,
|
|
|
|
publicPath: true,
|
|
|
|
entrypoints: true
|
2020-06-17 10:44:59 +00:00
|
|
|
})
|
|
|
|
],
|
|
|
|
performance: {
|
|
|
|
hints: false
|
|
|
|
}
|
2020-10-15 10:01:32 +00:00
|
|
|
};
|