pub struct Frontmatter {
pub raw: String,
pub data: Option<Value>,
pub pos: SourcePos,
}Expand description
The frontmatter block. data is the parsed YAML in the JSON value shape the TS
yaml package’s toJS() gives, or None when the YAML does not parse. pos is
the opening --- fence (line 1). The frontmatter plane finds the line of a key, and
the error of YAML that does not parse, by reading raw.
Fields§
§raw: Stringinter-fence YAML text, fences stripped
data: Option<Value>the parsed YAML, or None when it does not parse
pos: SourcePosthe opening --- fence
Trait Implementations§
Source§impl Clone for Frontmatter
impl Clone for Frontmatter
Source§impl Debug for Frontmatter
impl Debug for Frontmatter
Source§impl PartialEq for Frontmatter
impl PartialEq for Frontmatter
impl StructuralPartialEq for Frontmatter
Auto Trait Implementations§
impl Freeze for Frontmatter
impl RefUnwindSafe for Frontmatter
impl Send for Frontmatter
impl Sync for Frontmatter
impl Unpin for Frontmatter
impl UnsafeUnpin for Frontmatter
impl UnwindSafe for Frontmatter
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