Embeds
Publishing
Displaying your end-users content
Once your end-user has published their documents that they made with your Embed editor - you will want a way to preview that document live without the editor UI.
Each user’s document
has multiple versioned content
but each document only has exactly one published content
.
Whenever your users edit a document
, this will create a new versioned content
. Then, when they decide to publish - the latest content
will be used as the “published” content.
Retrieving document content
You can retrieve a user document’s content(s) via the @mirinhq/admin
sdk:
Rendering the content in preview
Finally, to render the specified content without the editor UI - all you need to do is to render the <Preview />
component with the relevant contentId
.