page grid image fixes

This commit is contained in:
tmshv committed 2020-03-03 08:08:55 +03:00
1 parent e800de1f92
commit 6e110e3dd7
3 files changed
+8 -4

No files matched your search

+4
View File
@@ -6,6 +6,10 @@ export type ResizeOptions = {
}
export function resizeImage(src: string, options: ResizeOptions): string {
if (!src || src === '') {
return null
}
return `https://images.weserv.nl/?url=${src}&w=${options.width}&h=${options.height}&n=-1`
}