Join the Webstudio community

Updated 3 days ago

Directus CMS - Post integration

I am testing the data integration from Directus CMS.
1) Looking on post, I can access the post content, but within webstudio the text contains typical html format elements, e.g. <p> ... </p> or <h> ... </h> How do I view this in the correctly formated ? Rich-text?
2) For images DirectUs returns a unique id, not an URL string. Is there a way to convert this to an URL?
Thank you in advance.
O
j
a
4 comments
  1. sounds like a case for content embed component which renders html
  1. API must provide a full url
@andyplay do you mean an image in a rich text field or images in general?
for general images, you can set a variable in Webstudio (best on the Global root) that contains "{directus_domain}/assets/". Then on the image url field on webstudio you can bind first this variable and concat the id from the CMS fetch to it.
Thank you, I am going to try this
Add a reply
Sign up and join the conversation on Discord