+++
# -----------------------------------------------------------------------
# Do not edit this file. It is automatically generated by API Documenter.
# -----------------------------------------------------------------------
title = "AppPlugin"
keywords = ["grafana","documentation","sdk","@grafana/data"]
type = "docs"
+++
## AppPlugin class
Signature
```typescript
export declare class AppPlugin extends GrafanaPlugin>
```
Import
```typescript
import { AppPlugin } from '@grafana/data';
```
Properties
| Property | Modifiers | Type | Description |
| --- | --- | --- | --- |
| [angularPages](#angularpages-property) | | {
[component: string]: any;
}
| |
| [root](#root-property) | | ComponentClass<AppRootProps<T>>
| |
| [rootNav](#rootnav-property) | | NavModel
| |
Methods
| Method | Modifiers | Description |
| --- | --- | --- |
| [init(meta)](#init-method) | | Called after the module has loaded, and before the app is used. This function may be called multiple times on the same instance. The first time, this.meta
will be undefined |
| [setComponentsFromLegacyExports(pluginExports)](#setcomponentsfromlegacyexports-method) | | |
| [setRootPage(root, rootNav)](#setrootpage-method) | | Set the component displayed under: /a/${plugin-id}/\* |
### angularPages property
Signature
```typescript
angularPages?: {
[component: string]: any;
};
```
### root property
Signature
```typescript
root?: ComponentClass>;
```
### rootNav property
Signature
```typescript
rootNav?: NavModel;
```
### init method
Called after the module has loaded, and before the app is used. This function may be called multiple times on the same instance. The first time, `this.meta` will be undefined
Signature
```typescript
init(meta: AppPluginMeta): void;
```
Parameters
| Parameter | Type | Description |
| --- | --- | --- |
| meta | AppPluginMeta
| |
Returns:
`void`
### setComponentsFromLegacyExports method
Signature
```typescript
setComponentsFromLegacyExports(pluginExports: any): void;
```
Parameters
| Parameter | Type | Description |
| --- | --- | --- |
| pluginExports | any
| |
Returns:
`void`
### setRootPage method
Set the component displayed under: /a/${plugin-id}/\*
Signature
```typescript
setRootPage(root: ComponentClass>, rootNav?: NavModel): this;
```
Parameters
| Parameter | Type | Description |
| --- | --- | --- |
| root | ComponentClass<AppRootProps<T>>
| |
| rootNav | NavModel
| |
Returns:
`this`