TypeError: _co.login is not a function

this is my login.ts

import { Component } from ‘@angular/core’;
import { IonicPage, NavController, NavParams } from ‘ionic-angular’;


selector: ‘page-login’,
templateUrl: ‘login.html’,
export class LoginPage {

constructor(public navCtrl: NavController, public navParams: NavParams) {
// navigateToPage(pageName: string) {
// pageName === ‘TabsPage’ ? this.navCtrl.setRoot(pageName) : this.navCtrl.push(pageName);
// }


this is my login.html

LoginPage logo

while i run my app than i got this error:

TypeError: _co.login is not a function
at Object.eval [as handleEvent] (ng:///LoginPageModule/LoginPage.ngfactory.js:34:31)
at handleEvent (http://localhost:8100/build/vendor.js:14274:155)
at callWithDebugContext (http://localhost:8100/build/vendor.js:15783:42)
at Object.debugHandleEvent [as handleEvent] (http://localhost:8100/build/vendor.js:15370:12)
at dispatchEvent (http://localhost:8100/build/vendor.js:10689:25)
at http://localhost:8100/build/vendor.js:13028:38
at SafeSubscriber.schedulerFn [as _next] (http://localhost:8100/build/vendor.js:5039:36)
at SafeSubscriber.__tryOrUnsub (http://localhost:8100/build/vendor.js:20899:16)
at SafeSubscriber.next (http://localhost:8100/build/vendor.js:20846:22)
at Subscriber._next (http://localhost:8100/build/vendor.js:20786:26)

while i use console to view the error: than it shows this error:

LoginPage.html:36 ERROR CONTEXT DebugContext_

It show the error in this line:

<app-login-form (loginStatus)=“login($event)”>


look here https://devdactic.com/10-ionic-problems/

Best regards, anna-liebt

Hi @anna_liebt thanks for reply. I check my code again as per instruction but the same error will occur again.

check again.

On my side your loginpageähhhlogo is broken. Use editor for code.

Best regards, anna-liebt