forked from nextcloud/groupfolders
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathwebpack.js
More file actions
34 lines (29 loc) Β· 745 Bytes
/
webpack.js
File metadata and controls
34 lines (29 loc) Β· 745 Bytes
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
const webpackConfig = require('@nextcloud/webpack-vue-config')
const webpackRules = require('@nextcloud/webpack-vue-config/rules')
const {CleanWebpackPlugin} = require('clean-webpack-plugin');
webpackConfig.entry = {
settings: [
'whatwg-fetch',
'./src/settings/index.tsx'
],
files: [
'./src/files.js'
]
}
webpackConfig.resolve.extensions = [...webpackConfig.resolve.extensions, '.jsx', '.ts', '.tsx']
webpackConfig.plugins.push(new CleanWebpackPlugin())
webpackRules.RULE_TSX = {
test: /\.tsx?$/,
use: [
{
loader: 'babel-loader',
options: {
babelrc: false,
plugins: ['react-hot-loader/babel'],
},
},
'ts-loader'
]
}
webpackConfig.module.rules = Object.values(webpackRules)
module.exports = webpackConfig