How should I handle dynamic images?
Unanswered
Japanese anchovy posted this in #help-forum
Japanese anchovyOP
Currently in my app, users can upload a single image that gets uploaded to appwrite storage, and I store the corresponding image url from appwrite in my database.
Currently, there is no image transformation being performed during the upload.
I want to know what is the best way to display these images, and also keeping image optimization in mind? I want the images to be in a square aspect ratio in all viewports, and be contained in the square.
Currently, there is no image transformation being performed during the upload.
I want to know what is the best way to display these images, and also keeping image optimization in mind? I want the images to be in a square aspect ratio in all viewports, and be contained in the square.
1 Reply
Holland Lop
You can use next/image to optimize images for you and you can make it square with styles like aspectRatio: 1/1 or setting same width and height and then playing with objectFit style