Performances optimizations WIP
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
2020-04-17 14:33:49 +02:00
parent bb5689f0b6
commit 3c05d6d222
17 changed files with 211 additions and 181 deletions

View File

@@ -1,10 +1,11 @@
import { apiEndpoints } from './store'
/*
** Get thumbnail from API
*/
export const getThumbnail = (id, width, height, type = 'crop', quality = 75) => {
export const getThumbnail = (id, width, height, type = 'crop', quality = 80) => {
const ratio = 1.5
width = !width ? Math.round(height * ratio) : width
height = !height ? Math.round(width / ratio) : height