Open Cliffzz opened 8 years ago
Reproduce repo: https://github.com/Cliffzz/flow-router-replace-state
When using FlowRouter.withReplaceState in onRendered the url's won't replace properly and the history is messed up:
FlowRouter.withReplaceState
Example:
Template.one.onRendered(function () { FlowRouter.withReplaceState(function() { FlowRouter.go('/2'); }); });
When I set a Meteor.setTimeout it works as expected:
Meteor.setTimeout
Template.oneWithTimeout.onRendered(function () { Meteor.setTimeout(function () { FlowRouter.withReplaceState(function () { FlowRouter.go('/2'); }) }, 100); });
Reproduce repo: https://github.com/Cliffzz/flow-router-replace-state
When using
FlowRouter.withReplaceState
in onRendered the url's won't replace properly and the history is messed up:Example:
When I set a
Meteor.setTimeout
it works as expected: