From 43a4a7162932873dad027afb8026522b1c104b2d Mon Sep 17 00:00:00 2001 From: Tim Lancina Date: Sun, 4 Oct 2015 16:03:03 -0500 Subject: [PATCH] chore(tab): tab api docs --- ionic/components/tabs/tab.ts | 35 +++++++++++++++++++++++++++++------ 1 file changed, 29 insertions(+), 6 deletions(-) diff --git a/ionic/components/tabs/tab.ts b/ionic/components/tabs/tab.ts index 24afe6c9a9..cf07a0afeb 100644 --- a/ionic/components/tabs/tab.ts +++ b/ionic/components/tabs/tab.ts @@ -7,14 +7,37 @@ import {Tabs} from './tabs'; /** - * @name ionTab - * @requires ionTabs - * @description - * Contains a tab's content. The content only exists while the given tab is selected. + * Tab components are basic navigation controllers used with [Tabs](). Much like + * [Nav](), they are a subclass of [NavController]() and are used to navigate to + * views and manipulate the navigation stack of a particular tab. * - * @usage + * For basic Tabs usage, see the [Tabs section]() of the component docs. + * + * Like Nav, you must set a root view to be loaded initially for each Tab with + * the 'root' property: + * ``` + * import {GettingStartedPage} from 'getting-started'; + * @App({ + * template: ` + * + * + * ` + * }) + * class MyApp { + * constructor(){ + * this.tabOneRoot = GettingStartedPage; + * this.tabTwoRoot = GettingStartedPage; + * } + * } + * ``` + * + * To change the title and icon for each tab, use the `tab-title` and `tab-icon` + * properties: * ```html - * + * + * + * + * * ``` */ @Component({