New strapi user and having issues with getting images to display

Paul is 100% correct here. However, I would use an environmental variable in place of a string directly in your const for the imageUrl.

This environmental variable should be your Strapi URL either locally, in staging, or in production.

The output for your JSON will be the full image path if you use a third party image provider.

2 Likes