Next.js Discord

Discord Forum

Dealing with API Fetched Images

Unanswered
Prairie Warbler posted this in #help-forum
Open in Discord
Avatar
Prairie WarblerOP
Hey folks! 👋

Quick question: I'm using Next.js' "Image" component with images fetched from an API.
Since I don't have the image dimensions, how should I handle the width prop requirement?

Should I ask the backend team to include width and height in the API response, or are there other solutions?

Thanks!
Image

0 Replies