Skip to content

Commit

Permalink
docs: add guidance on extension metadata (#1060)
Browse files Browse the repository at this point in the history
Co-authored-by: Joseph Perez <[email protected]>
  • Loading branch information
sympatheticmoose and josmperez authored Aug 20, 2024
1 parent 9a22308 commit fc147a7
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,12 @@ Read more about extensions under [key concepts](../../key-concepts/ui-extensions

<ExtensionPoints/>

:::warning

You must [update](#updating-pluginjson-metadata) your `plugin.json` metadata to list any registered extensions.

:::

## Links

### Register a link
Expand Down Expand Up @@ -217,6 +223,25 @@ export const plugin = new AppPlugin().addComponent({
});
```

## Updating plugin.json metadata

Once you have defined a link or component extension to be registered against an extension point, you must update your `plugin.json` metadata.

For example:

```json
"extensions": [
{
"extensionPointId": "grafana/dashboard/panel/menu/v1",
"type": "link"
"title": "My app",
"description": "Link to my app"
}
]
```

For more information, see the `plugin.json` [reference](../../reference/metadata.md#extensions).

## Troubleshooting

### My link is not appearing
Expand Down
2 changes: 1 addition & 1 deletion docusaurus/docs/reference/metadata.md
Original file line number Diff line number Diff line change
Expand Up @@ -311,7 +311,7 @@ Parameters for the token authentication request.

## extensions

The list of extensions that the plugin registers below other extension points.
List of link and component extensions which the plugin registers to given extension points.

### Properties

Expand Down

0 comments on commit fc147a7

Please sign in to comment.