Registry of document action keys. Extend via declaration merging to
register a custom action key. Use never as the value type; the values
are unused, and indexed access (DocumentActionKeys[K]) is not part of
the public contract.
declaremodule'sanity' { interfaceDocumentActionKeys { myPlugin: never } }
Once registered, MyAction.action = 'myPlugin' type-checks, and other
plugins can target the action for replacement.
To match only Sanity-defined actions exhaustively, narrow with
isSanityDefinedAction.
Registry of document action keys. Extend via declaration merging to register a custom action key. Use
neveras the value type; the values are unused, and indexed access (DocumentActionKeys[K]) is not part of the public contract.Once registered,
MyAction.action = 'myPlugin'type-checks, and other plugins can target the action for replacement.To match only Sanity-defined actions exhaustively, narrow with
isSanityDefinedAction.