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/`.

30 lines (21 loc) 535 B
import {FormBuilder, Validators} from 'angular2/angular2'; import {Page, NavController} from 'ionic/ionic' @Page({ templateUrl: 'app/<%= fileName %>/<%= fileName %>.html' }) class <%= jsClassName %> { constructor(nav: NavController ) { this.nav = nav; var fb = new FormBuilder(); this.loginForm = fb.group({ email: ['', Validators.required], password: ['', Validators.required], }); } doLogin() { console.log(this.loginForm.value); } doSignup() { this.nav.push(SignupPage) } }