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

feat(history): Reset history.current when all apps are destroyed #3298

Merged
merged 4 commits into from
Aug 31, 2020

Conversation

nightnei
Copy link

This resolves #3294

@nightnei nightnei changed the title feat(history): Reset history.current when all apps are destroyed [WIP] feat(history): Reset history.current when all apps are destroyed Aug 17, 2020
@nightnei nightnei changed the title [WIP] feat(history): Reset history.current when all apps are destroyed feat(history): Reset history.current when all apps are destroyed Aug 17, 2020
@nightnei
Copy link
Author

nightnei commented Aug 17, 2020

@posva @joeldenning look at the PR, please

Copy link
Contributor

@joeldenning joeldenning left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, left a few comments.

@@ -252,11 +252,17 @@ export class History {
// Default implementation is empty
}

teardownListeners () {
teardown () {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If we rename this method, it might make sense to rename the setupListeners method, too.

setupListeners () {

src/history/base.js Show resolved Hide resolved
this.pending = null
}

teardown () {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we can just put everything inside here as I don't think it makes sense to call teardownListeners or resetHistoryState separately

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@posva done

@nightnei nightnei requested a review from posva August 26, 2020 08:55
Copy link
Member

@posva posva left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you!

@posva posva merged commit c69ff7b into vuejs:dev Aug 31, 2020
@nightnei
Copy link
Author

nightnei commented Sep 1, 2020

Thank you!

Thank you for your effort of supporting and developing vue :)

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

Successfully merging this pull request may close these issues.

Reset history.current on destroy app
3 participants