Custom components

Portable text opens cross-platform possibilities
Portable text opens cross-platform possibilities
  

groq

// The GROQ query to get the image value for the block above *[_type == "sanity.imageAsset"] { _id, url, extension, "aspectRatio": metadata.dimensions.aspectRatio, }

An impactful section

To wow readers with nested Portable Text

Blocks can also come inline:

Hey there at 7/8/2024, 11:16:03 PM!

And custom annotations & marks let you do ALL sorts of fun stuff! Or boring useful & rich extensions, like links and footnotes1 .

Doing it yourself

These examples are available here. You should also read the docs and reach out in the Sanity community Slack (we have a #svelte channel) in case you have any questions 😉

  1. Which could have their own PortableText 🤯. See this guide for how to implement footnotes.

    👆