mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-11-09 16:16:41 +08:00
docs(): update examples
This commit is contained in:
@ -2,12 +2,20 @@ import { Component, Element, Listen, Prop } from '@stencil/core';
|
||||
import { ComponentProps, NavComponent } from '../../interface';
|
||||
|
||||
@Component({
|
||||
tag: 'ion-nav-set-root',
|
||||
tag: 'ion-nav-set-root'
|
||||
})
|
||||
export class NavSetRoot {
|
||||
|
||||
@Element() el!: HTMLElement;
|
||||
|
||||
/**
|
||||
* Component you want to make root for the navigation stack
|
||||
*
|
||||
*/
|
||||
@Prop() component?: NavComponent;
|
||||
|
||||
/**
|
||||
* Data you want to pass to the component as props
|
||||
*/
|
||||
@Prop() componentProps?: ComponentProps;
|
||||
|
||||
@Listen('child:click')
|
||||
@ -19,5 +27,4 @@ export class NavSetRoot {
|
||||
}
|
||||
return Promise.resolve(null);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@ -1,5 +1,7 @@
|
||||
# ion-nav-set-root
|
||||
|
||||
`NavSetRoot` is an element that allows you to set the root of the current navigation stack.
|
||||
It is the element form a calling `NavController.setRoot()`
|
||||
|
||||
|
||||
<!-- Auto Generated Below -->
|
||||
|
||||
Reference in New Issue
Block a user