Open deeppresentation opened 3 years ago
Hello,
It surely is possible. I would greatly appreciate a PR and guide you through the process. Basically you'd want the asset name generation to be configurable here in this file
@deeppresentation
You can use this inside of the wpackio.project.js
webpackConfig: (config, merge, appDir, isDev) => {
const customRule = {
optimization: {
splitChunks: {
chunks: "all",
cacheGroups: {
commons: {
test: /[\\/]node_modules[\\/]/,
name(module, chunks, cacheGroupKey) {
if (isDev) return "vendors";
const moduleFileName = module
.identifier()
.split("/")
.reduceRight((item) => item);
const allChunksNames = chunks.map((item) => item.name).join("-");
return `${cacheGroupKey}-${allChunksNames}-${moduleFileName}`;
},
chunks: "all",
minSize: 0,
},
},
},
},
};
return merge(config, customRule);
}
Would it be possible to remove '~' symbol from asset name? One of my customer of wp plugin, that I sell is complaining about that. Sending an info from him:
We use a bunch of rules in .htaccess to block malicious requests. For more info, please have a look here.
One of these rules is as follow: (# 6G:[REQUEST STRINGS]) RedirectMatch 403 (?i)(~|`|<|>|:|;|,|%|\|\s|{|}|[|]||)
Thank you