A link extension allows to render a link on the screen and navigate to another page when clicked by a user.
Name | Type | Description |
---|---|---|
label * | string | Text to be used as the label of the link. |
weight | number |
Determines the order in which this extension appears respect to others in the same location. Extensions are displayed top to bottom or left to right in order of ascending weight. |
url * | string | Defines a URL that's going to be used for the link. |
* required
Always remember to check the documentation of each product's extension point and supported attributes.
Read more information about Revealing extension points on the page.
Name | Type | Description |
---|---|---|
@clientside-extension * | - | Indicates that the next function is an extension factory to be consumed by the webpack plugin. |
@extension-point * | string | Defines the location where the extension will be rendered. |
@condition | string | Condition, UrlReadingCondition |
Defines one or multiple conditions that must be satisfied for the extension to be displayed. The conditions are evaluated on the server, and created with Java. If one of the conditions is not met, the code of the extension won't be loaded in the client. For more information about the conditions please refer to the examples of Web items documentation. |
* required
1 2import { LinkExtension } from '@atlassian/clientside-extensions'; /** * @clientside-extension * @extension-point reff.plugins-example-location */ export default LinkExtension.factory((extensionAPI, context) => ({ label: 'Go to DAC', url: 'https://developer.atlassian.com/', }));
1 2import { LinkExtension } from '@atlassian/clientside-extensions'; interface ExampleContext { title: string; url: string; } /** * @clientside-extension * @extension-point reff.plugins-example-location */ export default LinkExtension.factory<ExampleContext>((extensionAPI, context) => ({ label: `Go to ${context.title}`, url: context.url, }));
Rate this page: