Cosmic JS Blog Stay tuned for community news, company announcements and updates from the Cosmic JS team.

Introducing Object Revision History



We're excited to announce that Revision History is now available for all of your Cosmic JS Objects. This means that you now have the power to go back in time to previous versions, save new versions without publishing live and more (click on screenshots to zoom):


1. Objects remain published while you save changes to draft
You now have the ability to keep your published Objects while saving new versions to Draft.  Many have requested this and we're happy to now make this possible πŸ˜€ .  To unpublish the Object, click the new "Unpublish" button.


2. View prior changes
You can view all prior revisions on Objects (since this release date) by clicking the Revision History modal link.


3. Rollback to prior changes
To roll back to a prior version simply click on a revision and Save Draft or Publish in the Edit Object revision view.


We're excited about rolling this out as it makes collaboration between developers and editors that more comfortable.  No need to worry about mistakes when the revert button is just a click away.

If you would like to join our mission to help teams collaborate around building great products together, join our Community and follow us on Twitter.

You may also like


In this installment of the Cosmic JS Developer Spotlight Series, we sat down with Owen Liversidge, a Web Developer residing in Atlanta, Georgia who's currently helping lead the development charge at renowned game development company Tripwire Interactive. Owen just built Tripwire's new corporate website on a React and Cosmic stack. Follow Owen on LinkedIn or GitHub, and enjoy the Q/A.

The Cosmic CLI is a great way to use all of the powerful features of the Cosmic API from the comfort of your command-line tool.  With this release, you now have some powerful capabilities to demo and deploy Cosmic Apps for faster development and collaboration.

It's now faster and easier to make the content on your webpages dynamic.  The Official Cosmic JS JavaScript Client now comes with a minified browser version that allows you to add the power of Cosmic JS cloud-hosted content into your HTML page with a single file.  Download the Cosmic JS browser file then copy and paste this real-working browser example into an html file to check it out:

<!DOCTYPE html>
<html>
<head>
  <title>Cosmic JS Easy Browser Example</title>
</head>
<body>
<h1 id="title">If you see this, something isn't working...</h1>
<div id="content"></div>
<div id="metafields"></div>
<script src="cosmicjs.browser.min.js"></script>
<script>
var config = {
  bucket: {
    slug: 'easy-browser-example'
  },
  object: {
    slug: 'home'
  }
};
Cosmic.getObject(config, config.object, function(err, res) {
  var object = res.object;
  document.getElementById('title').innerHTML = object.title;
  document.getElementById('content').innerHTML = object.content;
  var metafields = object.metafields;
  var images = '';
  metafields.forEach(function(metafield){
    images += '<h2>' + metafield.title + '</h2>';
    images += '<img width="300" src="https://cosmicjs.com/uploads/' + metafield.value + '"/>';
    images += '<br><br>';
  })
  document.getElementById('metafields').innerHTML = images;
});
</script>
</body>
</html>

Sign in to your Cosmic JS account and connect this example to one of your buckets to see how easy it is to create powerful CMS-powered websites and app with Cosmic JS.


The Cosmic CLI puts you in the cockpit of your Cosmic JS Dashboard, giving you access to the powerful features of the Cosmic JS API, all from the comfort of your command line interface.

Don’t project, just build it cool and easily usable.

Make it the best option available.

Make it the product YOU want to use.

In this installment of the Cosmic JS Developer Spotlight Series, we sat down with Dallas-based React Developer Joe Warren. Joe is a DevMountain graduate and currently interning with Call-em-All, an SMS technology platform based in Frisco, Texas. Follow Joe on GitHub and Twitter, and enjoy the Q/A.