-
Notifications
You must be signed in to change notification settings - Fork 60
Open
Labels
questionFurther information is requestedFurther information is requested
Description
Hi π
Our directus instance currently only supports login via OAuth (e.g. github).
We would like to use this package, but it seems like you only support login via username/password (e.g. see documentation here: https://nuxt-directus-docs.vercel.app/composables/usedirectusauth#login )
Our current workaround is to manually include a "Login via XYZ" button in the nuxt frontend and have that then again redirect to the nuxt website once, the login/auth flow has completed.
However, when I then try to access the user:
const { fetchUser, setUser } = useDirectusAuth();
let user = useDirectusUser();
if (!user.value) {
const user = await fetchUser();
console.log("Fetched User", user);
setUser(user.value);
}
I only ever get undefined.
Am I missing something or is the whole user composable simply not fit to support this use case?
Any hint would be highly appreciated π
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
questionFurther information is requestedFurther information is requested