survirtual/vue-adal

Ability to access user

Closed this issue · 2 comments

Please can you add an accessor to current user so that we can display information, roles...

Like stated here : https://github.com/matt-ankerson/vue-adal
return this.authenticationContext.getCachedUser().profile;

If you import AuthenticationContext from 'vue-adal' it has a property called "user" -- just call AuthenticationContext.user.profile and you should be good to go.

I have a pretty robust example of the functionality, let me clean it up and add some functionality to this package. There's a lot more that needs to happen to really handle the auth process than this package currently exposes!

Take a look at latest & the readme; I added a lot more details on the whole flow of the auth process as well as additional helpers using axios.