acdlite / redux-router

Redux bindings for React Router – keep your router state inside your Redux store
MIT License
2.3k stars 200 forks source link

Create new action type INIT_ROUTES for initial route loading #183

Closed apapirovski closed 8 years ago

apapirovski commented 8 years ago

This should finally fix IE9 (#125) and all the extraneous replaceState on initial load. See #107 for more info.

@Scarysize let me know if you need me to clear anything up. There's a test there to confirm that we don't trigger replaceState more than necessary.

I ended up creating a new action because modifying REPLACE_ROUTES to handle both cases seemed like it would be way too brittle and heavy-handed.

Scarysize commented 8 years ago

@apapirovski wow nice. I actually had a similar solution "in progress" as it was a major issue. Also good job including a test!