streamlit-datalist
streamlit-datalist copied to clipboard
Datalist element for Streamlit
Streamlit Datalist
This component brings datalists to Streamlit. Contrary to regular selectboxes, where the user is contrained to the options in the dropdown list, datalists can receive values that weren't available.
To install this component, run the following command:
pip install streamlit-datalist
Importing and using the package can be done as follows:
from streamlit_datalist import stDatalist
my_selection = stDatalist("This datalist is...", ["great", "cool", "neat"])

The component takes the following parameters:
-
label: string
A name to display on top of the component. -
options: list
List of options to display in the dropdown. -
index: int (optional, default None)
Index of the list element to be displayed as a default value. Defaults to None. -
key: int, str (optional, default None)
Component's key. Required when multiple datalists will be used in the Streamlit app. -
disabled: bool (optional, default False)
Use this attribute to enable/disable the widget.