This Jac plugin adds a streamlit command line option for conveniently running streamlit apps written in Jac.
Project description
jac_streamlit Plugin Documentation
The jac_streamlit
plugin is a powerful tool that allows you to run and test Streamlit apps written in Jac. This documentation will guide you through the installation process and provide instructions on how to run and test your Jac Streamlit apps.
Installation
To install the jac_streamlit
plugin, you can use pip:
pip install jac_streamlit
Running Jac Streamlit Apps
To run a Streamlit app written in Jac, you can use the following command:
jac streamlit app.jac
Replace app.jac
with the path to your Jac Streamlit app file.
Generating Graphs with Jac Streamlit
If you want to visualize the graph of your Jac Streamlit app in a browser, you can use the following command:
jac dot_view app.jac
This will open up a Streamlit app in your browser, displaying the graph of your Jac Streamlit app.
Testing Jac Streamlit Apps
To test your Jac Streamlit app using the Streamlit testing framework, you can follow these steps:
- Import the
AppTest
class fromjac_streamlit
:
from jac_streamlit import AppTest
- Use the
AppTest.from_jac_file(filename)
method to create an instance ofAppTest
for your Jac Streamlit app:
app_test = AppTest.from_jac_file(filename)
Replace filename
with the path to your Jac Streamlit app file.
- You can now use the
app_test
instance to test your Jac Streamlit app using the Streamlit testing methodology.
Please note that the testing methodology for Jac Streamlit apps is similar to the one used for regular Streamlit apps.
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
Built Distribution
File details
Details for the file jaclang_streamlit-0.0.2.tar.gz
.
File metadata
- Download URL: jaclang_streamlit-0.0.2.tar.gz
- Upload date:
- Size: 3.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.8.3 CPython/3.12.0 Linux/5.15.153.1-microsoft-standard-WSL2
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 2adbfd2584c045e90052c959b8eb701d0eadb17f8e8682f50155e1962248981a |
|
MD5 | 958829eb2f29bb460f965752a9033190 |
|
BLAKE2b-256 | 686780125f3822ad95e4f9adf961d7ee2ac94ca9aae24f02be1114addc5a11d9 |
File details
Details for the file jaclang_streamlit-0.0.2-py3-none-any.whl
.
File metadata
- Download URL: jaclang_streamlit-0.0.2-py3-none-any.whl
- Upload date:
- Size: 5.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.8.3 CPython/3.12.0 Linux/5.15.153.1-microsoft-standard-WSL2
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | ae0df46377ff787a95d424a34a04cbfc4b9b91830369d13806a473fdff3c51ab |
|
MD5 | da6771a1c928139af2c12bc265d691c5 |
|
BLAKE2b-256 | 37ca099a6309d43ad2aa177982a2155e622858b1a7356cdc179f436598b7d325 |