(#1) - WebPack bundling of JS and CSS

This commit is contained in:
Martin Slachta
2026-06-12 11:25:57 +02:00
parent 0d829845c4
commit 2a630228ad
23 changed files with 115 additions and 70 deletions
+17
View File
@@ -0,0 +1,17 @@
const defaultConfig = require('@wordpress/scripts/config/webpack.config');
const defaultEntry = defaultConfig.entry;
module.exports = {
...defaultConfig,
entry: async () => {
const entries = typeof defaultEntry === 'function'
? await defaultEntry()
: defaultEntry;
return {
...entries,
client: './src/client.js',
admin: './src/admin.js',
};
},
};