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.0.tar.gz
(639.2 kB
view hashes)
Built Distribution
Close
Hashes for streamlit_supabase_auth-1.0.0.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | ca63190bdf57d94c8dedd72989ef6ebc17d5933d0642d75c995a94d394cf0380 |
|
MD5 | 063357d5c01f3ba94f7bfdec182a6f8e |
|
BLAKE2b-256 | 1fadda2db94c92369b0b6710e0b1adc3b93beaef5f1243d3d5828b223997da0f |
Close
Hashes for streamlit_supabase_auth-1.0.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | a87018945ba5ccd5db69e2119d240852d04af3f1de6c116b7909e8095e86c3bf |
|
MD5 | 39e4a115c1b95aa62ef545b71900855a |
|
BLAKE2b-256 | 81351c7ec90b28fd914bb987df766be922e65afae7e59f798033180e204040d6 |