Skip to main content

CLI to quickly scaffold custom Streamlit components (HTML, CSS, JS and Python) using st.components.v2.component

Project description

🧩 streamlit-generate-component

A simple CLI to quickly scaffold custom components for Streamlit.

It generates everything you need to get started:

  • HTML
  • CSS
  • JavaScript
  • Python wrapper using st.components.v2.component

Ideal for developers who want to organize their components and start quickly with a ready-to-use template.

🚀 Installation

pip install streamlit-generate-component

⚡ Usage

streamlit-generate-component my_component
or
streamlit-gc my_component
or
st-gc my_component

This will generate:

my_component/
├── __init__.py
├── my_component.py
├── my_component.html
├── my_component.css
└── my_component.js

🧪 Example

import streamlit as st
from my_component import my_component

my_component()

🔥 Features

  • One-command component scaffolding
  • Organized structure
  • Ready to plug into any Streamlit app

🛠 Requirements

  • Python 3.8+
  • Streamlit

Developer’s YouTube channel

https://www.youtube.com/@cafecombug

📄 License

MIT

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_generate_component-0.1.0.tar.gz (3.6 kB view details)

Uploaded Source

Built Distribution

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

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

Uploaded Python 3

File details

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

File metadata

File hashes

Hashes for streamlit_generate_component-0.1.0.tar.gz
Algorithm Hash digest
SHA256 198465cc91b12e9ac72083949fb1127af8c06620b9ddbf34b28d6ec5d99f0fb2
MD5 955f5f0d698ac52253d5ae7d7ff42ba9
BLAKE2b-256 f79aa927bbb268719e5a9db84600c2ffb3f9c8aa97e6aa874a7e4c55016d3e83

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for streamlit_generate_component-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 bb4e85b50766accfe3f5e157d9d7b89b65cb4338f9002a84857e77ef19b25462
MD5 a23f97daa3b656b6aa5efbd45f37e2cc
BLAKE2b-256 3d331652bd2f8c31ac1dc71f435c32cf3da75cd056356acb1e276c9923d9ff5d

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