Adding code blocks (and other structured content)

Posted by James on February 16, 2020

One of the challenges/opportunities we have is that we've got an Angular component library that uses TypeScript interfaces to initialise components. You can generate that interface data from a CMS, obviously, but it needs to be fairly structured.

To date I've been using Drupal paragraphs to do that. It's OK, but I have to do a lot of processing on the Druapal node object - which is very heavilty nested - before I can push it into the index that we use to store our API data. I was wondering whether Contentful would let me do that.

I can see that there's a way to embed other content items within existing content items, which is what I'm going to do here:

I'm interested to see what this is going to look like in the API.