1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
import { createClient } from "@/utils/supabase/server";
import UsersTable from "@/components/ui/dashboard/UsersTable";
export default async function Users() {
const supabase = createClient();
const { data, error } = await supabase.from('users').select("*");
if (error) {
throw new Error(error.message);
}
return (
<UsersTable data={data} />
);
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
import { createClient } from "@/utils/supabase/server";
import UsersTable from "@/components/ui/dashboard/UsersTable";
export default async function Users() {
const supabase = createClient();
const { data, error } = await supabase.from('users').select("*");
if (error) {
throw new Error(error.message);
}
return (
<UsersTable data={data} />
);
}