-
Notifications
You must be signed in to change notification settings - Fork 973
Conversation
Update the URL bar at load start instead of load end since that is what most browsers do.
@@ -63,6 +63,13 @@ class UrlBar extends ImmutableComponent { | |||
AppActions.setNavBarFocused(true) | |||
} | |||
|
|||
componentWillReceiveProps (newProps) { | |||
let location = newProps.activeFrameProps.get('location') // TODO: update this during redirects |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the location
prop on the frame isn't getting updated during redirects. help fixing this would be appreciated.
test case:
- open a new tab
- load google.com, which redirects to https://www.google.com/foobar. URL bar is updated correctly to https://www.google.com/foobar.
- switch to another tab
- switch back to the original tab. the URL bar displays the original URL ('http://google.com') instead of the actual URL in the frame.
Looking good, hope the comments help. Haven't tried them but I think that's how to fix. |
Thanks for the detailed comments and appstate documentation! I've updated the pull request to use the frame location prop. This doesn't seem to be working on |
Looks great, nice work! |
Fixed the redirect issue in a1eb2fb |
Update the url bar when changing active tabs or doing top-level redirects.
@bbondy to review