responsive-loader
responsive-loader copied to clipboard
Custom contenthash length in options.name
Is there a way to specify a custom contenthash length? It seems the loader is ignoring the custom length placeholder option for contenthash, e.g.
options: {
...
name: '[path][name]-[width].[contenthash:8].[ext]',
...
}
Because of server config not directly under my control I need the contenthash to be exactly 8 char long, but when using this config, the 8is ignored, and the file is written to disk with a 32 char long contenthash.
I managed to overcome this by manually truncating the produced filename inside the outputPath config function but this obviuously feels hackish.
It looks like this is totally intentional on your side, so I'd like to know:
- Why is this by design?
- Is there a better way to overcome my (silly, I know) problem?
Kudos for your great work, and thank you for taking the time to read this (probably trivial) issue!