Docs · Guides

Managing Extensions#

Verso ships with a set of built-in language kernels, themes, and layouts, and every one of them is an extension. You add more the same way: from the in-app marketplace, by declaring them on a notebook, or by pointing Verso at a local build during development. This guide covers finding, installing, trusting, enabling, and requiring extensions from a user's point of view. If you want to build one, start with Getting Started with Verso Extensions.

The Extensions panel#

Open the Extensions panel from the sidebar. It has two parts:

  • A package list under the search box. Everything this notebook requires is listed here, and typing filters it while searching your package sources for more. A package is described the same way whether it is installed or not: its publisher, what it is, how many people use it, and, once installed, what it adds to Verso. Install state sits on the row itself rather than in a separate section.
  • A list of loaded extensions, grouped by what they provide (kernels, renderers, themes, layouts, and so on), each with an On/Off toggle. Built-in extensions live here too, since they come with Verso rather than from a package.

The Extensions panel: a package list with install state on each row, above the loaded extensions grouped by capability

Two chips under the search box state what the list cannot say row by row: installing records the package in this notebook, not on your machine, and results come from the package sources configured on your machine. If you have not customized NuGet, that means nuget.org. There is no separate Verso-only feed: any package that ships a Verso extension is installable, and any private feed in your NuGet configuration is searched too.

Installing an extension#

Search for a package, choose a version from the picker if you want something other than the latest, and select Install. The first time you install a package from NuGet, Verso asks for your consent before loading it (see Trust and consent below).

Installed packages are unpacked into a managed store on disk:

  • macOS and Linux: ~/.verso/extensions/<package-id>/<version>/<target-framework>/
  • Windows: %APPDATA%\verso\extensions\<package-id>\<version>\<target-framework>\

Each version lives in its own folder, so multiple versions can coexist. Inside a version folder, assemblies are grouped by the .NET runtime they were installed for (for example net8.0), so notebook hosts running on different .NET versions can share the same store.

Once a package is installed, its row lists what it added: a kernel, a layout engine, a theme, and so on. A package that loaded but contributed no extension point at all is marked as adding nothing, which is worth knowing since the marketplace searches all of NuGet and will happily install an ordinary library.

To remove a package, use the Remove button on its row. Removal takes the package out of this notebook's requirements and revokes its trust, so installing it again asks for consent afresh. Whatever it already loaded stays active until the notebook is reopened.

Because an extension is executable code, Verso asks before it loads anything downloaded from a feed. When a package needs approval, a consent dialog lists it and lets you approve or deny. Approving loads the extension; denying leaves it installed but not loaded.

Approvals are remembered so you are not asked again on every session. Trust is pinned to the exact version you approved. If a notebook later asks for a different version of the same package, Verso prompts again rather than silently trusting the new build.

Loading a local assembly from a path (see Loading during development) does not prompt, since you are pointing at your own file rather than downloading one.

Enabling and disabling#

The On/Off toggle next to a loaded extension turns it off without uninstalling it, which is handy for isolating behavior or muting an extension you do not currently need. Turning it back on re-registers whatever it provides.

Enable and disable state is a personal preference stored locally on your machine (in browser storage for the web app, or the editor's state in VS Code). It is not written into the .verso file and does not travel with the notebook, so disabling an extension does not affect anyone else who opens the same notebook.

Requiring extensions for a notebook#

A notebook can declare the extensions it depends on so they are present before it runs. In the .verso file this lives under notebook metadata:

"metadata": {
  "extensions": {
    "required": ["Contoso.Verso.ChartLayout@1.2.0"],
    "optional": []
  }
}

Each entry is a package reference: PackageId or PackageId@Version for a marketplace package, or local:PackageId@Version for one loaded from the managed store. An entry with no version means "latest," which Verso resolves to a concrete version and pins on first approval.

Required extensions are resolved and loaded before the notebook renders, so a layout, kernel, or cell type that the notebook depends on is ready on the first paint rather than appearing a moment later. When you open a notebook:

  • If a required extension is installed, trusted, and available, it loads quietly.
  • If it needs approval, you get a consent prompt.
  • If it cannot be found, is not approved, or the feed is unreachable with nothing cached, the notebook still opens, and Verso shows a notice that the extension could not be loaded. Any layout, kernel, or cell type it would have provided is simply absent until you resolve it.

When an extension is unavailable#

If a required extension fails to load, Verso surfaces a notice, and its row in the Extensions panel is marked Not loaded with the reason stated underneath. To resolve it, install or approve the extension, then reopen the notebook or run the cell that loads it. If the notebook's chosen layout came from the missing extension, Verso falls back to a built-in layout so the notebook stays usable.

Loading during development#

You do not need to publish to a feed to try an extension you are building. Two options load one directly:

  • From a notebook, use the #!extension magic command with a path to the compiled assembly:

#!extension ./MyExtension/bin/Debug/net8.0/MyExtension.dll

The path is resolved relative to the notebook's directory, and a local assembly loads without a consent prompt.

  • From the CLI, point any command at a directory of extension assemblies:

bash verso serve notebook.verso --extensions ./MyExtension/bin/Debug/net8.0/

The --extensions flag works on serve, run, repl, convert, and export. In VS Code, set the verso.extensionsPath setting to the same directory.

See Getting Started with Verso Extensions for the development loop and Packaging and Publishing for turning a build into a package others can install from the marketplace.

See also#