forked from contao/contao
-
Notifications
You must be signed in to change notification settings - Fork 0
/
webpack.config.js
42 lines (36 loc) · 1.6 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
40
41
42
const Encore = require('@symfony/webpack-encore');
Encore
.setOutputPath('core-bundle/public/')
.setPublicPath('/bundles/contaocore')
.setManifestKeyPrefix('')
.cleanupOutputBeforeBuild()
.disableSingleRuntimeChunk()
.enableSourceMaps()
.enableVersioning()
.addEntry('backend', './core-bundle/assets/backend.js')
;
const jsConfig = Encore.getWebpackConfig();
Encore.reset();
Encore
.setOutputPath('core-bundle/contao/themes/flexible')
.setPublicPath('/system/themes/flexible')
.setManifestKeyPrefix('')
.cleanupOutputBeforeBuild(['*.css', '*.json'])
.disableSingleRuntimeChunk()
.enableSourceMaps()
.enableVersioning()
.configureCssLoader(config => {
config.url = false;
})
.addStyleEntry('backend', './core-bundle/contao/themes/flexible/styles/main.css')
.addStyleEntry('confirm', './core-bundle/contao/themes/flexible/styles/confirm.css')
.addStyleEntry('conflict', './core-bundle/contao/themes/flexible/styles/conflict.css')
.addStyleEntry('diff', './core-bundle/contao/themes/flexible/styles/diff.css')
.addStyleEntry('help', './core-bundle/contao/themes/flexible/styles/help.css')
.addStyleEntry('login', './core-bundle/contao/themes/flexible/styles/login.css')
.addStyleEntry('popup', './core-bundle/contao/themes/flexible/styles/popup.css')
.addStyleEntry('tinymce', './core-bundle/contao/themes/flexible/styles/tinymce.css')
.addStyleEntry('tinymce-dark', './core-bundle/contao/themes/flexible/styles/tinymce-dark.css')
;
const themeConfig = Encore.getWebpackConfig();
module.exports = [jsConfig, themeConfig];