Added support for avif images
This commit is contained in:
@@ -18,7 +18,7 @@ const storage = multer.diskStorage({
|
|||||||
});
|
});
|
||||||
|
|
||||||
const ALLOWED_MIMES = [
|
const ALLOWED_MIMES = [
|
||||||
'image/jpeg', 'image/png', 'image/webp', 'image/heic',
|
'image/jpeg', 'image/png', 'image/webp', 'image/heic', 'image/avif',
|
||||||
'application/pdf',
|
'application/pdf',
|
||||||
];
|
];
|
||||||
|
|
||||||
|
|||||||
@@ -14,7 +14,7 @@ const VARIANTS: VariantSpec[] = [
|
|||||||
];
|
];
|
||||||
|
|
||||||
const RESIZABLE_MIMES = new Set([
|
const RESIZABLE_MIMES = new Set([
|
||||||
'image/jpeg', 'image/png', 'image/webp', 'image/heic',
|
'image/jpeg', 'image/png', 'image/webp', 'image/heic', 'image/avif',
|
||||||
]);
|
]);
|
||||||
|
|
||||||
export function isResizable(mimeType: string): boolean {
|
export function isResizable(mimeType: string): boolean {
|
||||||
|
|||||||
Reference in New Issue
Block a user