How to Preview Content in Cosmic JS


Cosmic JS is dedicated to helping blended teams of developers and content editors collaborate to build apps faster. Here is a brief tutorial on setting up Preview Links in your Cosmic JS Bucket. 

Preview Cosmic JS Content in 3 Steps 

It's easy to set up Preview links on your Object Types to allow your writers to easily preview changes to content in draft or published state.  To add preview buttons to your Objects, simply go to the Object Type you want to Preview and click Settings > Preview Link.

Settings > Preview Link

Add your Preview Link (dynamically add the object slug with the [object_slug] shortcode).  If you would like to view Draft status Objects, you will need to make sure your web app queries the endpoint with ?status=all.  View the API documentation for more information on how to access your Objects in draft status.

Preview Link Slug

Once your Preview Link is available, you can draft content and save it. Then Click the Preview button located at the top right in the Edit Object page.

Cosmic JS Preview Button

I hope that you've found this tutorial helpful. If you have questions or comments about Content Editor Features in the Cosmic JS system, I'd love to hear about them. 

carson@cosmicjs.com 

Was this article helpful?

Thank you! Your input helps us improve our articles and resources. If you have any other questions or comments, please contact support.

You may also like


See how easy it is to create a browser based video game when using Cosmic JS to manage all of your data.
Thanks to all who attended our first webinar / AMA last week. There was some great engagement and questions that helped steer the screen-share webinar for users in the Cosmic Community as well as first-time visitors to the system. If you missed it, check out the video and attend our next one.
The relationship between content and code has come to an end.
Publish Blog Articles to a clean and simple UI with Apollo Blog, powered by Apollo Graphql client and Cosmic JS.
Cosmic JS allows you to easily create nested structures and upload media files. We learn how nested structures are built and how you can fetch such data from Cosmic JS API to use in a simple music site app.
A website boilerplate satisfies some common website requirements including dynamic pages, blog articles, author management, SEO ability, contact form and website search.