Widget registry
Where the widgets on /widgets come from, how to list them in a self-hosted Grist, and how to add a widget you built with the SDK.
/widgets lists two kinds of widgets:
- the catalog, built and maintained in this repository, each with its own page: what it does, its columns, its access and its install URL;
- community widgets, from
awesome-grist-widgets,
a public list of Grist custom widgets built with
grist-widget-sdk.
The catalog in a self-hosted Grist
A self-hosted Grist can offer the catalog in its custom widget gallery, next to Grist Labs' own widgets. Add it as a plugin:
- Set
GRIST_USER_ROOTto a directory Grist keeps (in Docker, a mounted volume such as/persist), and createplugins/grist-widgetsin it. - Save the catalog's list there as
widgets.json:curl -o widgets.json https://gristwidgets.com/widgets/grist-widgets.json - Next to it, write
manifest.yml:name: grist-widget-sdk catalog components: widgets: widgets.json - Restart Grist.
Each widget in the list is at its install URL,
/widgets/<slug>/v<major>/: it takes that major version's fixes and
features, never a breaking change. Your copy of the list never goes stale
for the documents that use it; download it again to offer a widget's new
major version, or a new widget.
A document that added a widget from the gallery stays on its major version. To move it to a new one, pick the widget again in the gallery: Grist then asks for its columns and options again.
GRIST_WIDGET_LIST_URL also takes a list, but it replaces Grist Labs'
own. Every document that uses one of their widgets (Calendar, Map,
Markdown…) would show a blank section: Grist finds those widgets by their
id in that list.
The same list, with the github.io install URLs, is at
https://arthurblanchon.github.io/grist-widget-sdk/widgets/grist-widgets.json.
Community widgets
Where the details come from
Each widget's deploy publishes grist-widget.json next to the widget, on
every channel (create-grist-widget manifest):
its name, description, access level and the columns it expects from its
declaration (defineGristWidget), its version and license, and the
SDK version it was built with. The registry reads it from the widget's
install URL, and so does the /widgets page, live: what you see
there is what the widget's latest release declares, not text typed into a
list.
The registry also publishes the list in Grist's own format,
grist-widgets.json. A self-hosted Grist shows those widgets in its custom
widget gallery with:
GRIST_WIDGET_LIST_URL=https://raw.githubusercontent.com/ArthurBlanchon/awesome-grist-widgets/main/grist-widgets.jsonWidgets marked Reference are checked by this SDK's CI against every change before it is released: typecheck, tests and build on each pull request, and weekly inside a real Grist (Real widgets).
Submitting a widget
- Add an entry with two URLs to that repo's
registry.json:repoUrl, the widget's GitHub repository, andwidgetUrl, the install URL its README documents (a widget scaffolded withnpm create grist-widgetwrites it there at its first release,https://<owner>.github.io/<repo>/latest/). - Run
npm run build: it fetches the widget's manifest and rewrites the README and the JSON files. Commit them. - Open a pull request. CI fetches every manifest again: it must be a release build that names the entry's own repository.
A coding agent can do this end to end: see that repo's
AGENTS.md.
The one rule it must never break: never invent a widgetUrl.
Requirements
- Built with
grist-widget-sdk, deployed withcreate-grist-widget0.3.32 or later, so it publishesgrist-widget.json. - A public, open-source GitHub repository, with a license, documentation, installation instructions, and active maintenance.
Building a widget to submit
Start with the quickstart or the CLI reference.
A widget scaffolded today publishes its manifest from its first deploy; an
older one gets it with create-grist-widget upgrade.