mirror of
https://github.com/supabase/supabase.git
synced 2026-05-07 01:10:15 -04:00
d8bd6b047c
## I have read the [CONTRIBUTING.md](https://github.com/supabase/supabase/blob/master/CONTRIBUTING.md) file. YES <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **Documentation** * Updated examples and guides to use Supabase publishable (client) keys instead of anon keys for client-side usage across frameworks and platforms. * Renamed environment variable examples and .env templates to reflect publishable key naming. * Adjusted sample requests and client-init examples to send/use the publishable key via the apikey header where applicable. * Updated references from service_role to secret for server-side credential guidance. <!-- end of auto-generated comment: release notes by coderabbit.ai --> --------- Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com> Co-authored-by: fadymak <fady@fadymak.com>
Supabase Auth with React Native
This example demonstrates how to use Supabase Auth with React Native and Expo.
Getting started
1. Create a Supabase project
Launch a new project in the Supabase Dashboard.
2. Configure environment variables
Create a .env file and populate with your Supabase connection variables:
You can find these in your Supabase Dashboard under Settings > API.
3. Install dependencies
npm install
4. Start the app
npm start
Follow the instructions in the terminal to open the app on your device or emulator.
Project structure
├── App.tsx # Main app component
├── components/
│ └── Auth.tsx # Authentication form component
├── lib/
│ └── supabase.ts # Supabase client configuration
├── app.json # Expo configuration
├── package.json # Dependencies
└── tsconfig.json # TypeScript configuration
Features
- Email/password sign up
- Email/password sign in
- Session persistence with AsyncStorage
- Automatic token refresh