# AbilityComponent > **NOTE** > > This component is supported since API version 9. > > The APIs of this module are system APIs and cannot be called by third-party applications. **\** is a container for independently displaying an ability. ## Constraints Using **\** requires a signature and related permissions. **\** is rendered independently and cannot be overlaid with other display content. **\** cannot process input events. Events are directly distributed to the internal ability for processing without passing through the current ability. Only width and height can be set for **\**. These attributes are mandatory and cannot be dynamically updated. The ability to be started must be resizeable. The ability to start must be set not to display on the recent tasks screen. ## Required Permissions ohos.permission.INFUSE_EVENTS ohos.permission.CONTROL_ABILITY_STACKS ohos.permission.INTEGRATED_ABILITY ohos.permission.INTEGRATED_INTERIOR_WINDOW ## Child Components Not supported ## APIs AbilityComponent(value: {want : Want, controller? : AbilityController}) - Parameters | Name| Type| Mandatory| Default Value| Description| | -------- | -------- | -------- | -------- | -------- | | want | [Want](../../reference/apis/js-apis-application-Want.md) | Yes| - | Description of the default ability to load.| | controller | [AbilityController](#abilityController) | No| - | Ability controller.| ## Events | Name| Description| | -------- | -------- | | onReady() => void | Called when this **\** is started. You can then use APIs in the **\**.| | onDestroy() => void | Called when this **\** is destroyed.| | onAbilityCreated(name: string) => void | Called when the specified ability is loaded.| | onAbilityMoveToFont() => void | Called when this ability is moved to the foreground.| | onAbilityWillRemove() => void | Called when this ability is about to be removed.| ## AbilityController Implements an ability controller, which provides the control APIs for **\**. | Name | Description | | --------------------------------------- | ------------------------------------------------------------ | | startAbility() => want | Loads an ability inside the **\**.
**want**: description of the ability to be loaded.| | preformBackPress() => void | Performs a return operation inside the **\**. | | getStackCount() => void | Obtains the number of tasks in the internal task stack of the **\**. | ## Example ```ts // xxx.ets @Entry @Component struct MyComponent { @State controller: AbilityController = new AbilityController() build() { Column() { AbilityComponent({ want: { bundleName: '', abilityName: '' }, controller: this.controller }) .onReady(() => { console.log('AbilityComponent ready'); }) .onDestory(() => { console.log('AbilityComponent destory'); }) Button("Start New") .onClick(() => { this.controller.startAbility({ bundleName: '', abilityName: '' }); }) Button("Back") .onClick(() => { if (this.controller.getStacjCount() > 1) { this.controller.preformBackPress(); } }) } } } ```