sitcod3 commited on
Commit
b3c4f92
·
verified ·
1 Parent(s): 4dbfff9

Upload src/lib/supabaseClient.ts with huggingface_hub

Browse files
Files changed (1) hide show
  1. src/lib/supabaseClient.ts +12 -0
src/lib/supabaseClient.ts ADDED
@@ -0,0 +1,12 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import { createClient } from '@supabase/supabase-js';
2
+
3
+ const supabaseUrl = import.meta.env.VITE_SUPABASE_URL;
4
+ const supabaseAnonKey = import.meta.env.VITE_SUPABASE_ANON_KEY;
5
+
6
+ export const supabase = supabaseUrl && supabaseAnonKey
7
+ ? createClient(supabaseUrl, supabaseAnonKey)
8
+ : null;
9
+
10
+ export const isSupabaseConfigured = () => {
11
+ return !!supabase;
12
+ };