WIP Complete overhaul of all js

This commit is contained in:
Björn Fromme
2021-07-27 14:06:11 +02:00
parent a6834e0e8c
commit 7168e05852
22 changed files with 3152 additions and 5813 deletions
+16 -2
View File
@@ -17,14 +17,23 @@ Encore
.enableSourceMaps(!Encore.isProduction())
.cleanupOutputBeforeBuild()
.enablePostCssLoader()
.copyFiles([
{ from: './public/typo3conf/ext/ep_theme/Resources/Private/Assets/images', to: 'images/[name].[ext]' },
{ from: './public/typo3conf/ext/ep_theme/Resources/Private/Assets/images/icons', to: 'images/icons/[name].[ext]' },
{ from: './node_modules/leaflet/dist/images', to: 'images/[name].[ext]' },
])
.configureFilenames({
js: 'js/[name].js',
css: 'css/[name].css',
images: 'images/[name].[ext]'
})
.configureBabel(function (babelConfig) {
babelConfig.plugins = [ '@babel/plugin-proposal-object-rest-spread', '@babel/plugin-syntax-dynamic-import' ]
})
.configureBabelPresetEnv((config) => {
config.shippedProposals = true
config.useBuiltIns = 'usage'
config.corejs = 3
})
.configureWatchOptions(function (options) {
options.poll = 500;
options.ignored = /node_modules|vendor|fileadmin/;
@@ -54,7 +63,12 @@ Encore
.configureFilenames({
js: 'js/[name].js',
css: 'css/[name].css',
images: 'images/[name].[ext]'
})
.configureImageRule({
filename: 'images/[name].[ext]',
})
.configureFontRule({
filename: 'fonts/[name].[ext]',
})
.configureBabel(function (babelConfig) {
babelConfig.plugins = [ '@babel/plugin-proposal-object-rest-spread', '@babel/plugin-syntax-dynamic-import' ]