Trait sauron_core::Render 
source · pub trait Render {
    // Required method
    fn render_with_indent(
        &self,
        buffer: &mut dyn Write,
        indent: usize,
        compressed: bool
    ) -> Result;
    // Provided methods
    fn render(&self, buffer: &mut dyn Write) -> Result { ... }
    fn render_compressed(&self, buffer: &mut dyn Write) -> Result { ... }
    fn render_to_string(&self) -> String { ... }
    fn render_to_string_pretty(&self) -> String { ... }
    fn maybe_indent(
        &self,
        buffer: &mut dyn Write,
        indent: usize,
        compressed: bool
    ) -> Result { ... }
}Expand description
render node, elements to a writable buffer
Required Methods§
Provided Methods§
sourcefn render_compressed(&self, buffer: &mut dyn Write) -> Result
 
fn render_compressed(&self, buffer: &mut dyn Write) -> Result
no new_lines, no indents
sourcefn render_to_string(&self) -> String
 
fn render_to_string(&self) -> String
render compressed html to string
sourcefn render_to_string_pretty(&self) -> String
 
fn render_to_string_pretty(&self) -> String
render to string with nice indention