How to pass parameters in pop method of ionic2

后端 未结 8 1595
隐瞒了意图╮
隐瞒了意图╮ 2021-02-04 07:04

I tried passing parameters in push method of ionic2. like this

this.nav.push(SecondPage, {
    thing1: data1,
    thing2: data2
});

but is ther

8条回答
  •  忘了有多久
    2021-02-04 07:34

    Use popTo() instead of pop()

    popTo() has params? parameter where you can pass in your paramaters like so:

        this.nav.popTo(SecondPage, {
        thing1: data1,
        thing2: data2
    });
    

提交回复
热议问题