Hello, I recently started using Ionic to build hybrid apps, however I faced a lot of trouble since there is not much angular 2 info on the web. I could not make two way binding work, can you please check if am doing something wrong?
PS: I also wanted to implement parse, however could not find a proper place to initialize parse, any help on that will be also appreciated. Thanks in advance.
forgot-password.js
import { FormBuilder, Validators} from 'angular2/common';
import {Page, NavController, Alert } from 'ionic/ionic';
/*
Generated class for the ForgotPasswordPage page.
See http://ionicframework.com/docs/v2/components/#navigation for more info on
Ionic pages and navigation.
*/
@
Page({
templateUrl: 'build/pages/forgot-password/forgot-password.html',
})
export class ForgotPasswordPage {
constructor(nav: NavController, form: FormBuilder) {
this.nav = nav;
this.email = '';
Parse.initialize("id", "key");
this.passwordResetForm = form.group({
email: ["", Validators.required]
});
this.checkEmail = function () {
console.log(this.email);
}
}
}
forgot-password.html
<ion-content padding class="forgot-password">
<ion-list>
<ion-item>
<ion-input placeholder="E-posta">
<input type="text" [(ngModel)]="email">
</ion-input>
</ion-item>
</ion-list>
<button mblue-light class="full" (click)="checkEmail()" type="">Şifremi Sıfırla</button>
</ion-content>