feat: rewrite auth (#364)

* feat: wip rewrite auth

* feat: restructure folders and fix stories and tests

* feat: remove auth provider and fix tests
This commit is contained in:
Jérémy M
2023-06-23 17:49:50 +02:00
committed by GitHub
parent 1c7980b270
commit c6708b2c1f
54 changed files with 1268 additions and 584 deletions

View File

@ -1,7 +1,5 @@
import { gql } from '@apollo/client';
import { useGetCurrentUserQuery as generatedUseGetCurrentUserQuery } from '~/generated/graphql';
export const GET_CURRENT_USER = gql`
query GetCurrentUser($uuid: String) {
users: findManyUser(where: { id: { equals: $uuid } }) {
@ -30,11 +28,3 @@ export const GET_USERS = gql`
}
}
`;
export function useGetCurrentUserQuery(userId: string | null) {
return generatedUseGetCurrentUserQuery({
variables: {
uuid: userId,
},
});
}