pub struct MarkdownOptions<'a> {
pub comrak_options: ComrakOptions<'a>,
pub enable_custom_blocks: bool,
pub enable_syntax_highlighting: bool,
pub enable_enhanced_tables: bool,
pub syntax_theme: Option<String>,
}
Expand description
Options for configuring Markdown processing behavior.
Fields§
§comrak_options: ComrakOptions<'a>
Options for the underlying Comrak Markdown parser.
enable_custom_blocks: bool
Enable or disable processing of custom blocks (e.g., note, warning, tip).
enable_syntax_highlighting: bool
Enable or disable syntax highlighting for code blocks.
enable_enhanced_tables: bool
Enable or disable enhanced table formatting.
syntax_theme: Option<String>
Optional custom theme for syntax highlighting.
Implementations§
Source§impl<'a> MarkdownOptions<'a>
impl<'a> MarkdownOptions<'a>
Sourcepub fn with_custom_blocks(self, enable: bool) -> Self
pub fn with_custom_blocks(self, enable: bool) -> Self
Enables or disables custom blocks.
Sourcepub fn with_syntax_highlighting(self, enable: bool) -> Self
pub fn with_syntax_highlighting(self, enable: bool) -> Self
Enables or disables syntax highlighting for code blocks.
Sourcepub fn with_enhanced_tables(self, enable: bool) -> Self
pub fn with_enhanced_tables(self, enable: bool) -> Self
Enables or disables enhanced table formatting.
Sourcepub fn with_custom_theme(self, theme: String) -> Self
pub fn with_custom_theme(self, theme: String) -> Self
Sets a custom theme for syntax highlighting.
Sourcepub fn with_comrak_options(self, options: ComrakOptions<'a>) -> Self
pub fn with_comrak_options(self, options: ComrakOptions<'a>) -> Self
Sets custom Comrak options.
Trait Implementations§
Source§impl<'a> Clone for MarkdownOptions<'a>
impl<'a> Clone for MarkdownOptions<'a>
Source§fn clone(&self) -> MarkdownOptions<'a>
fn clone(&self) -> MarkdownOptions<'a>
Returns a copy 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 MarkdownOptions<'_>
impl Debug for MarkdownOptions<'_>
Auto Trait Implementations§
impl<'a> Freeze for MarkdownOptions<'a>
impl<'a> RefUnwindSafe for MarkdownOptions<'a>
impl<'a> Send for MarkdownOptions<'a>
impl<'a> Sync for MarkdownOptions<'a>
impl<'a> Unpin for MarkdownOptions<'a>
impl<'a> UnwindSafe for MarkdownOptions<'a>
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