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 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.2.2.tar.gz (6.2 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.2.2-py3-none-any.whl (7.0 kB view details)

Uploaded Python 3

File details

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

File metadata

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

File hashes

Hashes for clay_streamlit_one-0.2.2.tar.gz
Algorithm Hash digest
SHA256 a14f1980878bc8e1ccae9f9801f4063eaf9c8601f7462911a201dabb5d3d27e6
MD5 d55082a7b4533c3765d238bc74d68c8d
BLAKE2b-256 af9c74f13392d028ce91ecfd95bb5e8e35c2da96b01bb6868b485a04a8ff8177

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for clay_streamlit_one-0.2.2-py3-none-any.whl
Algorithm Hash digest
SHA256 c746f7f7617d4ed6c686b4250de9b4dc9e9e2cc85da8b030c51ff3f8f7558483
MD5 6d9e609602e207cc5263569da246aaf0
BLAKE2b-256 9ff60b094786ab4a18a54077b88d6a011a6474d5fad5b90608a914b18fac20d8

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