Skip to main content

Streamlit component that returns the user browser IANA timezone

Project description

streamlit-tz

Streamlit component that returns the user browser IANA timezone

Installation instructions

pip install streamlit-tz

Usage instructions

from datetime import datetime, UTC
from zoneinfo import ZoneInfo

import streamlit as st
from streamlit_tz import streamlit_tz


tz = streamlit_tz()
now = datetime.now(UTC)
st.write(f"Time UTC: {now}")
st.write(f"Time in {tz}: {now.astimezone(ZoneInfo(tz))}")

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

streamlit_tz-0.1.0.tar.gz (3.8 kB view details)

Uploaded Source

Built Distribution

streamlit_tz-0.1.0-py3-none-any.whl (4.6 kB view details)

Uploaded Python 3

File details

Details for the file streamlit_tz-0.1.0.tar.gz.

File metadata

  • Download URL: streamlit_tz-0.1.0.tar.gz
  • Upload date:
  • Size: 3.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.12.4

File hashes

Hashes for streamlit_tz-0.1.0.tar.gz
Algorithm Hash digest
SHA256 eae07c833166b985a509e5952738d9c0b7f140df0a1031c24f117780f66f3a2b
MD5 78fb89557adc87e6fe03a6a375b4f908
BLAKE2b-256 b289a0b1c81f2076f14083edd2eaa2682b6188cde7166398e54e098368714478

See more details on using hashes here.

File details

Details for the file streamlit_tz-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for streamlit_tz-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 833c5bfc17615aa271d9aaf833bed60bfeb40f3c72dc919af3b8cdc361728de2
MD5 3134ddb7a1f7189bfb760c0c88c3bc70
BLAKE2b-256 c5551a33c4a2dda5b2c6aeb90d835c820fd567b159d935667b07e1008d58ce2e

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page