JWT authentication with Supabase
Project description
streamlit-supabase-auth
Usage
Prerequisite:
- python >= 3.7
import streamlit as st
from streamlit_supabase_auth import login_form, logout_button
session = login_form(
url="https://xxxx.supabase.co",
apiKey="<SUPABASE_KEY>",
providers=["apple", "facebook", "github", "google"],
)
if not session:
return
# Update query param to reset url fragments
st.experimental_set_query_params(page=["success"])
with st.sidebar:
st.write(f"Welcome {session['user']['email']}")
logout_button()
More details in example directory.
Develop
docker-compose up --build
Or manually, start the frontend
cd streamlit_supabase_auth/frontend
npm install
npm run start
Followed by the example app
RELEASE=DEV streamlit run example/app.py
Publish
cd component/frontend
npm run build
cd ../..
pip install build
python -m build
Known Issues
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
streamlit_supabase_auth-1.0.1.tar.gz
(639.2 kB
view hashes)
Built Distribution
Close
Hashes for streamlit_supabase_auth-1.0.1.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 04e04bda7da066acf5d705acb1dec1d820eaef71efc741286a36f21dc31cc689 |
|
MD5 | a9b314678d569515ab981a30272d3737 |
|
BLAKE2b-256 | f72e45d06a86e4dbf02edee1bdee99faeb5a1948164760e87f81c0feaf22067a |
Close
Hashes for streamlit_supabase_auth-1.0.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | d7f53ea746aa59c6e7b216f37f5e45ce5fc9c8163028e12ea5c1dc739520e028 |
|
MD5 | 187d82675becd81447a0156c48fab6a6 |
|
BLAKE2b-256 | 20052c23f8d7e9174e297b83d0d37916326afb45ded7a79e14d17cb06d607593 |