fix: plugin ideal-image should generate filename with a hash even in development (#5334)

This commit is contained in:
Pierre-Gilles Leymarie 2021-08-11 17:14:57 +08:00 committed by GitHub
parent 236c33c6c1
commit ec1401ad80
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -41,9 +41,7 @@ export default function (
disable: !isProd,
// eslint-disable-next-line global-require
adapter: require('@docusaurus/responsive-loader/sharp'),
name: isProd
? 'assets/ideal-img/[name].[hash:hex:7].[width].[ext]'
: 'assets/ideal-img/[name].[width].[ext]',
name: 'assets/ideal-img/[name].[hash:hex:7].[width].[ext]',
...options,
},
},