https://github.com/socialfinancedigitallabs/sf-nova-vscode-extension
SF version of stlite vscode extension
https://github.com/socialfinancedigitallabs/sf-nova-vscode-extension
Last synced: 3 months ago
JSON representation
SF version of stlite vscode extension
- Host: GitHub
- URL: https://github.com/socialfinancedigitallabs/sf-nova-vscode-extension
- Owner: SocialFinanceDigitalLabs
- License: apache-2.0
- Created: 2023-05-13T09:34:58.000Z (about 2 years ago)
- Default Branch: main
- Last Pushed: 2024-09-12T18:23:34.000Z (9 months ago)
- Last Synced: 2024-12-29T11:19:40.124Z (5 months ago)
- Language: TypeScript
- Size: 991 KB
- Stars: 0
- Watchers: 3
- Forks: 0
- Open Issues: 6
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Welcome to the Streamlit Preview VSCode Extension
This VSCode extension is an adaptation of the [original stlite extension](https://marketplace.visualstudio.com/items?itemName=whitphx.vscode-stlite) in order to work on vscode web editor.
It provides a convenient way to preview Streamlit apps in an integrated VSCode panel. It is powered by a Wasm/Pyodide-ported version of Streamlit, "stlite", that runs on the browser without servers. This unique feature allows the extension to run on both VSCode desktop and VSCode Web, such as on the Github.dev, without the need for setup of Python or other dependencies. This makes serverless and full-remote development of Streamlit apps a reality.
## Usage
To use this extension, follow these steps:
1. Open the python entry file for your app
2. click on the sf-nova icon on the activity bar and click on the "Launch preview" button
3. The preview of your Streamlit app will be shown in the integrated VSCode panel.## Python Dependencies
The dependencies required to run your Streamlit app are read from the `requirements.txt` file. The package names must be written line by line in the file. When the preview panel is launched, the dependencies are installed. If the `requirements.txt` file is updated after the panel is launched, the installation will run again.
## stlite Restrictions and Differences
Please note that "stlite" is a customized version of Streamlit and may have some differences and restrictions compared to the original Streamlit. For more information, please see the GitHub repository for stlite: https://github.com/whitphx/stlite#limitations.
## Offline Usage
The current version of this extension uses `@stlite/mountable` in the same way as [described in the stlite README](https://github.com/whitphx/stlite#limitations), which means that the stlite resources are downloaded from the CDN every time the extension is launched. As a result, the extension cannot start offline.