Toast not showing


#1

My toast works perfectly, except I can’t see it, I couldn’t find anything in the docs nor stackoverflow. My toast receive parameters, I can see it showing as I inspect my chrome, it triggers its methods etc, I simply can’t manage to make it show. I have toast in another page which works completely.


#2

Have you tried removing the crust?


#3

How mature. No wonder why I found no answers


#4

Try posting your code. As is, there’s not much anyone can suggest aside from shots in the dark.


#5

It’s not shot in the dark, I described a behaviour. As I said, I have the same code working in another page:

showToastSignUp() {
let toast = this.toastCtrl.create({
message: this.toastMessage,
position: ‘middle’
});

toast.onDidDismiss(() => {
  console.log('Dismissed toast');
});

toast.present();

}

signUp() {
let info = {
email: this.email,
password: this.password,
};
this.backoffice.postSignUp((data, error)=> {
if (data) {
if (data.status) {
this.toastMessage = data.message;
this.showToastSignUp();
console.log(‘success’);
} else {
this.toastMessage = data.message;
this.showToastSignUp();
}

  } else {
    console.log('error');
  }
}, info);

}

I even removed duration


#6

Have you modified any SCSS?


#7

Is there something in the middle of the page that could be covering it? Have you tried setting position: ‘top’ or ‘bottom’ ?


#8

Tried both bottom and top. I also haven’t modified any scss for this page. However I tried calling the toast as the first thing on my code, this way it works.