Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

A new feature about pop method. #3164

Closed
HengCC opened this issue Aug 9, 2018 · 3 comments
Closed

A new feature about pop method. #3164

HengCC opened this issue Aug 9, 2018 · 3 comments

Comments

@HengCC
Copy link

HengCC commented Aug 9, 2018

Is it possible to do a markup action before jumping the page. For example, Actions.mark(), after doing a lot of jumps, I only need to execute Actions.popToMark(). I will return directly to the mark point.

@aksonov
Copy link
Owner

aksonov commented Aug 9, 2018

Yes, it is supported already, just use Actions.popTo('mark')

@aksonov aksonov closed this as completed Aug 9, 2018
@HengCC
Copy link
Author

HengCC commented Aug 9, 2018

@aksonov thanks,

But I mean, when I execute Actions.popToMark(), I don't know what the point I am marking. This point is automatically maintained in memory only when I execute Actions.mark().

For example:

Actions.mark(),
Actions[key1].call(),
Actions[key1].call(),....Actions[keyN].call(),

When Actions.popToMark() is executed again, it will return to the position of key1.

@aksonov
Copy link
Owner

aksonov commented Aug 9, 2018

It is out of scope for this component. You have to pass your custom reducer to manage state for proper action - you could do whatever you want there.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants