Plugins

Plugins add tools, panels, commands and skills to Modular. A plugin can have a server part, a web part and a desktop part.

Installing#

Settings → Extensions → Plugins has three tabs:

Modular ships with three plugins:

PluginWhat it does
Browser UseLets an agent open and drive browser tabs on the canvas (desktop only)
CC SwitchOffers the providers you set up in CC Switch as Modular providers
System InfoExposes facts about the machine through an API and a palette command

A plugin asks for permissions when it is installed; it gets only what you allow.

Writing a plugin#

A plugin is an npm package with a modular section in its package.json and the entry points it needs (server, web, desktop), built with @modular/plugin-sdk.

Start from the developer guide: packages/plugin-sdk/DEVELOPERS.md, also readable from a terminal with modular plugin docs.

While you work on it, run it inside the app with hot reload:

sh
modular plugin dev --package-dir ./my-plugin

The built-in plugins are working examples.