Using Tome Static and Tome Sync

Tome includes two sub-modules, Tome Static and Tome Sync, which can be used separately for specific use cases. This document will try to cover why you may want to only use one half of Tome.

Tome Static

The Tome Static sub-module handles static site (HTML) generation, and is useful if you are comfortable with your existing Drupal stack, but still want to run a static site on production.

When just running Tome Static, you'll need to decide how and when to kick off the static site generation process. In the future a "tome:static:watch" command may be added which you can run as a persistent background process, but for now you'll probably want to run "tome:static" in a cron job, which can also push the export directory to your hosting provider.

To get the same security benefit of running traditional Tome, you should lock down your editing environment so that only authorized users can access it. This can be accomplished by adding simple basic authentication to your site, or by requiring a VPN to access your editing environment.

Tome Sync

The Tome Sync sub-module handles static content export and import, and is useful if you want to build your site from scratch, or prefer to work with your content as JSON.

The use-cases for Tome Sync as a standalone module aren't completely clear right now, but there are a lot of possibilities for this sub-module without generating a static site. Maybe you want to migrate away from Drupal and JSON would make that easier, or you're using GatsbyJS which is lightning fast when using JSON files, or you want to archive a site's content and de-commission it from production. Tome Sync is powerful, so I encourage users to try it out and let me know if you find where it fits into your workflow.