pub struct FeaturesConfig {
pub code_spaces: bool,
pub clipboard: bool,
pub logging: bool,
pub timeout: f64,
pub savebrace: bool,
pub images: bool,
pub links: bool,
}Expand description
Feature flags configuration.
Controls which features are enabled in streamdown.
Fields§
§code_spaces: boolEnable space-indented code blocks (4 spaces = code). Default: false (only fenced code blocks are recognized)
clipboard: boolEnable clipboard integration for code blocks. Default: true
logging: boolEnable debug logging. Default: false
timeout: f64Timeout in seconds for streaming operations. Default: 0.1
savebrace: boolSave brace matching state. Default: true
images: boolEnable image rendering (where supported). Default: true
links: boolEnable link rendering with OSC 8 hyperlinks. Default: true
Implementations§
Source§impl FeaturesConfig
impl FeaturesConfig
Sourcepub fn merge(&mut self, other: &FeaturesConfig)
pub fn merge(&mut self, other: &FeaturesConfig)
Merge another FeaturesConfig into this one.
All fields are copied from other since they’re all
simple values with no “unset” state in TOML.
Sourcepub fn all_enabled() -> Self
pub fn all_enabled() -> Self
Create a new FeaturesConfig with all features enabled.
Sourcepub fn all_disabled() -> Self
pub fn all_disabled() -> Self
Create a new FeaturesConfig with all features disabled.
Trait Implementations§
Source§impl Clone for FeaturesConfig
impl Clone for FeaturesConfig
Source§fn clone(&self) -> FeaturesConfig
fn clone(&self) -> FeaturesConfig
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for FeaturesConfig
impl Debug for FeaturesConfig
Source§impl Default for FeaturesConfig
impl Default for FeaturesConfig
Source§impl<'de> Deserialize<'de> for FeaturesConfig
impl<'de> Deserialize<'de> for FeaturesConfig
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for FeaturesConfig
impl RefUnwindSafe for FeaturesConfig
impl Send for FeaturesConfig
impl Sync for FeaturesConfig
impl Unpin for FeaturesConfig
impl UnwindSafe for FeaturesConfig
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more