forked from LibreSign/libresign
-
Notifications
You must be signed in to change notification settings - Fork 0
/
webpack.config.js
39 lines (38 loc) · 1.02 KB
/
webpack.config.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
const { merge } = require('webpack-merge')
const path = require('path')
const nextcloudWebpackConfig = require('@nextcloud/webpack-vue-config')
module.exports = merge(nextcloudWebpackConfig, {
entry: {
tab: path.resolve(path.join('src', 'tab.js')),
settings: path.resolve(path.join('src', 'settings.js')),
external: path.resolve(path.join('src', 'external.js')),
validation: path.resolve(path.join('src', 'validation.js')),
},
optimization: process.env.NODE_ENV === 'production'
? { chunkIds: 'deterministic' }
: {},
devServer: {
port: 3000, // use any port suitable for your configuration
host: '0.0.0.0', // to accept connections from outside container
},
output: {
assetModuleFilename: '[name][ext]?v=[contenthash]',
},
module: {
rules: [
{
test: /\.(ttf|otf|eot|woff|woff2)$/,
type: 'asset/inline',
},
// Load raw SVGs to be able to inject them via v-html
{
test: /@mdi\/svg/,
type: 'asset/source',
},
{
resourceQuery: /raw/,
type: 'asset/source',
},
],
}
})