Skip to content
Realm LoreRelease 2026.9.1

Plugins ​

Plugins add features to Realm Lore, such as extra pages in the sidebar. Realm Lore doesn't come with any plugins installed. Plugins are for people comfortable installing or writing JavaScript.

WARNING

A plugin runs with the same access to your Mac as Realm Lore itself. Only install plugins from people you trust, and read the code first if you can.

Install a plugin ​

  1. Open Settings > Plugins.
  2. Under Plugins Folder, click Open. The folder is ~/Library/Application Support/realm-lore/plugins/.
  3. Copy the plugin's folder into it. Each plugin folder has a manifest.json and a main.js.
  4. Click the refresh button next to Open.
  5. Make sure Enable plugins is on, then turn on the plugin under Installed Plugins.

Plugins that add a page appear under a Plugins heading in the sidebar. Turn off Enable plugins to stop all plugins from loading at once.

Two example plugins are in the source repository: World Stats, which adds a statistics page for the active world, and Example Logger.

Write a plugin ​

A plugin is a folder containing:

  • manifest.json with an id, name and version, and optionally a description, author and main file name.
  • An ES module, usually main.js, whose default export has an onLoad(api) function and, optionally, onUnload().
json
{
  "id": "my-plugin",
  "name": "My Plugin",
  "version": "1.0.0",
  "description": "Does something useful.",
  "author": "You",
  "main": "main.js"
}

The api object passed to onLoad includes:

MemberUse
registerPanel({ panelId, panelFile, navLabel, navIcon })Adds a sidebar page. panelFile is a script in the plugin folder that exports a component.
fs.readFile, fs.writeFile, fs.existsRead and write files inside the Worlds folder.
on, off, emitSend and listen for events shared between plugins.
log, writeLogWrite messages to the console, or to .plugin-logs/<plugin id>.log in the Worlds folder.

Settings > Plugins > Writing a Plugin shows a minimal example, and the World Stats plugin in the repository shows how to build a panel.

Odd Omens is a one-person studio building privacy-first software.