Configure a JSON column in st.dataframe or st.data_editor.
Cells need to contain JSON strings or JSON-compatible objects. JSON columns are not editable at the moment. This command needs to be used in the column_config parameter of st.dataframe or st.data_editor.
Function signature[source] | |
---|---|
st.column_config.JsonColumn(label=None, *, width=None, help=None, pinned=None) | |
Parameters | |
label (str or None) | The label shown at the top of the column. If this is None (default), the column name is used. |
width ("small", "medium", "large", or None) | The display width of the column. If this is None (default), the column will be sized to fit the cell contents. Otherwise, this can be one of the following:
|
help (str or None) | A tooltip that gets displayed when hovering over the column label. If this is None (default), no tooltip is displayed. The tooltip can optionally contain GitHub-flavored Markdown, including the Markdown directives described in the body parameter of st.markdown. |
pinned (bool or None) | Whether the column is pinned. A pinned column will stay visible on the left side no matter where the user scrolls. If this is None (default), Streamlit will decide: index columns are pinned, and data columns are not pinned. |
Examples
Still have questions?
Our forums are full of helpful information and Streamlit experts.