authentification nocodebackend ok

This commit is contained in:
2026-02-08 16:12:25 +01:00
commit be5bd2b2bf
37 changed files with 9585 additions and 0 deletions

14
AuthContext.tsx Normal file
View File

@@ -0,0 +1,14 @@
import React, { createContext, useContext } from 'react';
import { useAuth as useAuthHook } from './hooks';
const AuthContext = createContext<any>(null);
export const AuthProvider: React.FC<{ children: React.ReactNode }> = ({ children }) => {
const auth = useAuthHook();
return <AuthContext.Provider value={auth}>{children}</AuthContext.Provider>;
};
// Ce hook permettra d'accéder à l'auth n'importe où
export function useAuthContext() {
return useContext(AuthContext);
}