Merge pull request #1603 from DeepChirp/image

chore: add `avif` to the list of supported image formats
This commit is contained in:
Jerry Wong
2024-11-11 15:13:02 +08:00
committed by GitHub

View File

@@ -6,7 +6,7 @@
'use strict'
hexo.extend.filter.register('before_post_render', data => {
const imgTestReg = /\.(png|jpe?g|gif|svg|webp)(\?.*)?$/i
const imgTestReg = /\.(png|jpe?g|gif|svg|webp|avif)(\?.*)?$/i
let { cover: coverVal, top_img: topImg } = data
// Add path to top_img and cover if post_asset_folder is enabled