SIDEBAR

Various enhancements to the Roam native sidebar!

Installation

You could use the Copy Extension button below to individually install this extension. To install, just paste anywhere in your Roam graph and click "Yes, I Know What I'm Doing".

Manual Installation

If the extension doesn't work after using the copy extension button above, try installing manually using the instructions below.

First create a block with the text {{[[roam/js]]}} on any page in your Roam DB. Then, create a single child of this block type three back ticks. A code block should appear. Copy this code and paste it into the child code block in your graph:

var existing = document.getElementById("roamjs-sidebar");
if (!existing) {
  var extension = document.createElement("script");
  extension.src = "https://roamjs.com/sidebar.js";
  extension.id = "roamjs-sidebar";
  extension.async = true;
  extension.type = "text/javascript";
  document.getElementsByTagName("head")[0].appendChild(extension);
}

Finally, click "Yes, I Know What I'm Doing".

Usage

The RoamJS sidebar extension introduces a bunch of features to the native right sidebar.

Expand/Collapse All

An icon will be rendered on the top left of the sidebar. Toggling it on and off will expand and collapse all of the windows in the right sidebar.

Save Sidebar

The second icon on the top left of the sidebar will allow you to save the current sidebar configuration. Give the configuration an easy to remember label for later. To load a saved sidebar, open the Roam Command Palette and click "Load Saved Sidebar". Pick the sidebar you want to load based on label and it will appear on the right sidebar! You also have the option to save your current page state which includes the name of the page and the currently focused block.

You may view your saved sidebars and even remove ones you are no longer using on the saved tab in the roam/js/sidebar page.

Autofocus

Whenever you open the right sidebar, your cursor will autofocus on the first block. This behavior is toggleable from the roam/js/sidebar page.

Pinned open

If your sidebar was open during your last Roam session, it will automatically open on load/reload.

Saved Filters

Roam natively supports includes/removes filters on pages. Those filters are not saved however when you add the page to the sidebar. Opening a page in the sidebar will persist the filters from the page.

Demo

Contributors

This extension is brought to you by RoamJS! If you are facing any issues reach out to support@roamjs.com or click on the chat button on the bottom right. If you get value from using this extension, consider sponsoring RoamJS by clicking on the button below!

A special thanks to those who's contributions also helped make this extension possible:

ROAMJS DIGEST

Add your email below to stay up to date on all RoamJS features, fixes, and news!

Other Extensions