UNPKG

ionic-framework

Version:

The ionic-framework package comes with both Javascript and Sass frontend dependencies, located in the root of the package, and a Node API, located in `tooling/`.

32 lines (23 loc) 600 B
import {FormBuilder, Validators} from 'angular2/angular2'; import {Page, NavController} from 'ionic/ionic'; @Page({ templateUrl: 'app/<%= fileName %>/<%= fileName %>.html' }) export class <%= jsClassName %> { constructor(nav: NavController) { this.nav = nav; var fb = new FormBuilder(); this.signupForm = fb.group({ name: ['', Validators.required], email: ['', Validators.required], password: ['', Validators.required], }); } doLogin() { this.nav.pop() } doSignup() { console.log(this.signupForm.value); this.nav.push(AppPage); } }