I have something like this:
blocks:[
{
imageURL: "../images/mediaAndText.jpg",
}
]
Causing an issue like in the attached screenshot.
I'm probably missing something obvious here?
Also here is my project structure
In your console, what URL is it trying to resolve for the images?
Relative paths won't cut it here. You'll have to point it to where they're served from
@denolfe, you're right and can I serve it from Payload or do I need to upload it to somewhere else? Here is what I get as the image source:
<img src="../images/mediaAndText.jpg">
You'll need to configure
/images
as static directory using express.static
https://expressjs.com/en/starter/static-files.htmland then you can use something like
/images/mediaAndText.jpg
Star
Discord
online
Get help straight from the Payload team with an Enterprise License.