This PR shows Supabase RLS server side with Remix world 🚀
By design, RLS is useful for client side code when you don't have backend / API.
Since Supabase's team add a way to link an access token to supabase client, It opens possibilities :D
It can replace all Prisma stuff if you want, but you'll have to handle your DB schema with supabase cli or manually.
Actual DB schema in this stack (made with and for Prisma) is not perfect to use only supabase sdk : I add some UID casts to match Prisma schema is RLS policies, some table column could have default value, etc...
Because this stack relies on Prisma first, I can't / don't want to remove it.
This PR shows Supabase RLS server side with Remix world 🚀 By design, RLS is useful for client side code when you don't have backend / API. Since Supabase's team add a way to link an access token to supabase client, It opens possibilities :D
It can replace all Prisma stuff if you want, but you'll have to handle your DB schema with supabase cli or manually. Actual DB schema in this stack (made with and for Prisma) is not perfect to use only supabase sdk : I add some UID casts to match Prisma schema is RLS policies, some table column could have default value, etc...
Because this stack relies on Prisma first, I can't / don't want to remove it.
For more info : https://supabase.com/docs/guides/auth/row-level-security