-
Notifications
You must be signed in to change notification settings - Fork 10
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
Allow for custom channels on route change. #17
Conversation
Allow for custom channels on route change.
I don't think this should have been merged. It seems to duplicate existing functionality and more importantly has no tests/use cases. @twilson63 In #16:
var state = mercury.struct({
route: Router()
});
state.route(function (change) {
console.log(change)
}) And more importantly:
This is the whole point of routeView({
'/': renderHome,
'/animals': renderAnimals,
'/animals/:id': renderAnimalItem
}, { route: state.route }) If you want to make requests you can either observe |
@coballast can you confirm that the above suggestions work for you? |
Thanks for your pull request, I made you a collaborator so that you can Thanks Tom On Thu, Mar 31, 2016 at 6:58 PM, nikuda [email protected] wrote:
Tom Wilson This e-mail may contain information that is confidential, privileged or |
I don't mind if you guys remove it. |
Thanks @twilson63. My NPM uid is I will revert the changes made in this PR when I get a free moment. Documentation is probably what needs to be updated too, to make usage clearer. |
Revert #17 and example/test/doc clean up
It is necessary on large single page apps to mutate the app state in some way when the route uri changes. This pull request adds route based callbacks for when the route uri changes. This addresses my concerns in #16 . All of the tests still pass.