Join GitHub today
BeforeRouteEnter hook executes mounted hook #2563
Steps to reproduce
In the sandbox go to
What is expected?
The mounted hook should not be executed.
What is actually happening?
If you open the console you can see that mounted hook gets executed.
I don't know if this is made by design, but since beforeRouteEnter runs before the component gets mount, the mounted hook should not be executed if from beforeRouteEnter hook you redirect to another path. It seems like a bug to me.
The callback passed to