1
1
mirror of https://github.com/aelve/guide.git synced 2024-11-25 18:56:52 +03:00
guide/front/build/webpack.server.conf.js
avele 9e4146b5bc
Front/chore/migrate to vuetify 2.0 (#348)
* Vuetify updated

* Correct component creation in dialog mixins

* Vuetify 2.0 migration

* Conflict dialog content style fixed

* Removed duplicate attribute
2019-08-03 06:18:26 +04:00

38 lines
919 B
JavaScript

const path = require('path')
const merge = require('webpack-merge')
const nodeExternals = require('webpack-node-externals')
const VueSSRServerPlugin = require('vue-server-renderer/server-plugin')
const WebpackBar = require('webpackbar')
const baseConfig = require('./webpack.base.conf')
const isProduction = process.env.NODE_ENV === 'production'
const webpackConfig = merge(baseConfig, {
mode: isProduction ? 'production' : 'development',
entry: path.resolve(__dirname, '../client/entry.server.ts'),
devtool: isProduction ? false : 'source-map',
target: 'node',
output: {
libraryTarget: 'commonjs2'
},
externals: nodeExternals({
whitelist: [
/\.css$/,
/\.sass$/,
/\.scss$/,
/\.svg$/,
/vuetify\/.*/
]
}),
plugins: [
new VueSSRServerPlugin(),
new WebpackBar({
name: 'Server',
color: 'orange'
})
]
})
module.exports = webpackConfig