Contentful logo

Contentful Community

Image embedded in the rich text field in contentful

Hi,
I am beginner in contentful development. I am trying to render the image embedded in the rich text. I have installed rich-text-react-renderer and rich-text-types to get the image url from the json object. But unable to retrieve it. Does any one dealt with similar issue and found the solution? Appreciate your help.
Thanks!
Sara

Hi Sara,
I created an app demo to render rich text elements, have a look at the source line 342 and 63, is the call to the render as react component.
I hope it helps

Hey Sara,

You might find the blog article useful. It has examples for if you’re using the GraphQL or REST APIs (client library/SDK).

Let me know how it goes!

Salma