auth0-vue3-ts icon indicating copy to clipboard operation
auth0-vue3-ts copied to clipboard

Why did you use NavigationGuardWithThis instead of NavigationGuard?

Open BenJackGill opened this issue 3 years ago • 1 comments

First of all, thank you for making this. It has helped me a lot.

But when implementing this as a router.beforeEach I had to change this line in auth/index.ts from NavigationGuardWithThis<undefined> to NavigationGuard.

So I'm wondering what was the significance of using NavigationGuardWithThis<undefined> in your original version?

I'm still learning JavaScript/TypeScript so I might be missing something, but it seems like routeGuard isn't using this. So is there any reason for choosing NavigationGuardWithThis<undefined> over NavigationGuard? Am I missing something important here?

BenJackGill avatar Oct 08 '21 00:10 BenJackGill

I used the sample made by Auth0 with minimal changes for it to work with Vue3.

alexeyzimarev avatar Oct 17 '21 06:10 alexeyzimarev