check webpack assets entrypoints

This commit is contained in:
2021-03-20 21:54:07 +01:00
parent 6efa795f2a
commit e78855fe0c
2 changed files with 38 additions and 18 deletions

View File

@@ -1,17 +1,26 @@
// this file loads all assets from the Chill main bundle
module.exports = function(encore, entries) {
module.exports = function(encore, entries)
{
// Push into "chill" entrypoint
entries.push(__dirname + '/Resources/public/main.js');
encore
.addEntry('login',
__dirname + '/Resources/public/modules/login_page/index.js')
.addEntry('tabs',
__dirname + '/Resources/public/modules/tabs/index.js')
.addEntry('ckeditor5',
__dirname + '/Resources/public/modules/ckeditor5/index.js')
// Add new separate entries
.addEntry('login', __dirname + '/Resources/public/modules/login_page/index.js')
.addEntry('tabs', __dirname + '/Resources/public/modules/tabs/index.js')
// chill2 assets
.addEntry('forkawesome', __dirname + '/Resources/public/modules/forkawesome/index.js')
// Alias are used by Webpack when trying to resolve modules
// cfr. https://github.com/symfony/webpack-encore/pull/217/files#diff-e727e4bdf3657fd1d798edcd6b099d6e092f8573cba266154583a746bba0f346
.addAliases({
ShowHide: __dirname + '/Resources/public/modules/show_hide/',
ChillMainSass: __dirname + '/Resources/public/sass'
// sass resolve
ChillMainSass: __dirname + '/Resources/public/sass',
// typescript resolve
ShowHide: __dirname + '/Resources/public/modules/show_hide'
})
;
};
};