Skip to main content

A minimal streamlit app framework

Project description

Clay-Streamlit

Are you tired of the boilerplate needed to actually run a useful streamlit app? I was.

  • Create multipage apps simply by defining list of pages

  • Each page has a name, lambda to show contents, and lambda to show sidebar

  • Run your code simply by calling python <myfile.py>

  • No need to complicate launch.json with streamlit run <myfile> commands

  • Makes debugging and working in containers simpler

from clay_streamlit_one import AppPage, ClayStreamlitApp

pages_list = [
        AppPage.AppPage("first page", 
            None, 
            lambda: st.button("This is a button for the first page") 
        ),
        AppPage.AppPage("Hi", 
            lambda: st.code(demo_code) and st.write("Success! ClayStreamlitApp is working"),
            None
        ),
        ]

myapp = ClayStreamlitApp.ClayStreamlitApp()
myapp.set_pages(pages_list)
myapp.run()

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

clay_streamlit_one-0.3.0.tar.gz (8.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

clay_streamlit_one-0.3.0-py3-none-any.whl (8.9 kB view details)

Uploaded Python 3

File details

Details for the file clay_streamlit_one-0.3.0.tar.gz.

File metadata

  • Download URL: clay_streamlit_one-0.3.0.tar.gz
  • Upload date:
  • Size: 8.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.9

File hashes

Hashes for clay_streamlit_one-0.3.0.tar.gz
Algorithm Hash digest
SHA256 5a41e41d8793c14118799e8fd6afe9d924c7e8ddf694f598c7deebbbfce33122
MD5 4af3281bde8b25e8f400ef0932ce7252
BLAKE2b-256 e3647117b67d24d4c81e5c0664eebc51031c651a9fa965625a8fce63468965f7

See more details on using hashes here.

File details

Details for the file clay_streamlit_one-0.3.0-py3-none-any.whl.

File metadata

File hashes

Hashes for clay_streamlit_one-0.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 623baa2591e0de5a9bb392672721b67e9e74b56dea1ff451d5684b2ea13aec7c
MD5 9289cb7a0bf947bd6d2a8ba8b6c81a7e
BLAKE2b-256 c132d97c55806a53efd3a00b5c8c52136c687647cabc4622230b803a45426174

See more details on using hashes here.

Supported by

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