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

Add entry.index and appHistory.canGoBack/canGoForward #55

Merged
merged 1 commit into from
Mar 4, 2021
Merged

Conversation

domenic
Copy link
Collaborator

@domenic domenic commented Mar 3, 2021

Closes #6.

@frehner
Copy link

frehner commented Mar 3, 2021

Do you think there would be a desire to allow navigateTo() (or a similarly-named method) to take in the index?

I think it's not a big deal if it doesn't though (e.g. appHistory.navigateTo(appHistory.entries[index].key) )

(maybe somewhat related to the discussion in #7 as well)

@domenic
Copy link
Collaborator Author

domenic commented Mar 3, 2021

Interesting. I'm unsure... I do think the discussion in #7 is more grounded in real use cases. Indices are a bit fragile.

@frehner
Copy link

frehner commented Mar 3, 2021

Do you think there would be a desire to allow navigateTo() (or a similarly-named method) to take in the index?

I think it's not a big deal if it doesn't though (e.g. appHistory.navigateTo(appHistory.entries[index].key) )

(maybe somewhat related to the discussion in #7 as well)

The more I think about this, the more I think it's not necessary - in any case where you have an entry's index you'll also have its key (right?). And like you mentioned, the indices are fragile.

@domenic domenic merged commit 9a35176 into main Mar 4, 2021
@domenic domenic deleted the index-etc branch April 16, 2021 20:52
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.

Adding sugar for current index/can go back/can go forward
2 participants