mirror of
https://github.com/ratatui-org/ratatui
synced 2024-11-22 12:43:16 +00:00
fe06f0c7b0
TableState, ListState, and ScrollbarState can now be serialized and deserialized using serde. ```rust #[derive(Debug, Clone, serde::Serialize, serde::Deserialize)] struct AppState { list_state: ListState, table_state: TableState, scrollbar_state: ScrollbarState, } let app_state = AppState::default(); let serialized = serde_json::to_string(app_state); let app_state = serde_json::from_str(serialized); ``` |
||
---|---|---|
.. | ||
backend_termion.rs | ||
border_macro.rs | ||
state_serde.rs | ||
stylize.rs | ||
terminal.rs | ||
widgets_barchart.rs | ||
widgets_block.rs | ||
widgets_calendar.rs | ||
widgets_canvas.rs | ||
widgets_chart.rs | ||
widgets_gauge.rs | ||
widgets_list.rs | ||
widgets_paragraph.rs | ||
widgets_table.rs | ||
widgets_tabs.rs |