-
Notifications
You must be signed in to change notification settings - Fork 141
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
Location.manageHistory: Consider dispatching the event for changes to route #190
Comments
This is an interesting idea, but I'm not sure exactly when it should be done or what other ramifications it might have. Do JS libraries usually do this - i.e. is there an established best-practice? Separately, shouldn't something like this be used to construct the event? |
That code is actually from Good question about best practices. It could even be that we should add this to |
manageHistory
currently maintains changes to the route internally but any other JS code listening for route events won't be notified when these updates happen. We can dispatch this event and rely on the browser to update theDynamic
for us. There are a few choices to consider, however, namely if we want the event to bubble, etc.browserHistoryWith
only provides half of the story thatmanageHistory
offers. However, if the browser were handling the updates for us, we could writemanageHistory
in terms ofbrowserHistoryWith
.The text was updated successfully, but these errors were encountered: