NavController.push() unfamiliar behaviour

I am using following code for going from one page to another but sometime I will see the elements of earlier pages into current page.I also remove page from the stack.

this.navCtrl.push(SecondPage, {
                          key: this.key
                    }).then(() => {
                        const index = this.viewCtrl.index;
                        for (let i = index; i >= 0; i--) {
                            this.navCtrl.remove(i);
                        }
                    });

Am I correct that you’re trying to make it impossible for the user to navigate back to an old page by removing them all from stack?

Yes, but even calling navCtrl.remove() method I can still see html view of previous pages into the current page. E.g. some button see in background of earlier page into current page.

Have you tried using navCtrl.setRoot(‘page’)?

Yes, I tried it work fine for pages navigation but I still get Modal content in background of some pages.