-
Notifications
You must be signed in to change notification settings - Fork 154
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
Fluxxor and React Router 1.x and ES6 #137
Comments
Hey, @manuelmazzuola, thanks for the info! One additional note, with React Router 1.0 RC1, you can use the new const createFluxComponent = (Component, props) => {
return <Component {...props} flux={flux} />;
};
React.render(
<Router createElement={createFluxElement}>
... |
Thank you, much more simply in this way |
I'm working on the same problem right now. Difficult that they choose to change the API so much but hopefully it's stable now. Any chance we could either push @manuelmazzuola 's example into the examples for future readers? One I figure my project out I'd be happy to write a version in 1.0 but I do think it makes sense to keep both examples side by side for a while as there are probably still people using pre-1.0 versions of react-router. |
@PendletonJones I'll definitely get the example in once React Router 1.0 comes out of release candidate status. In the meantime take a look at #141 if you're still having issues with this, and feel free to let me know if you continue to have problems. |
Bump |
Probably worth mentioning that this example no longer works: https://github.com/BinaryMuse/fluxxor/blob/master/examples/react-router/app/app.jsx. |
I'm trying to decide between using this and https://github.com/rackt/redux-simple-router. Can you advise? |
Hello,
I had a lot of troubles to run together
fluxxor
react-router 1.x
andES6
This is my solution, hoping will help someone.
With the new react router the
Handler
component has gone!I've copied, pasted and modified the
Root
component from thebaobab-react
module.In this way we can pass flux prop down to the components.
For the mixins I've used react-mixins
And then the real problem was the
StoreWatchMixin
mixin because it is a mixin and because the bindings, so I've resolved in this way:The autobind method is this:
The text was updated successfully, but these errors were encountered: