Note: This site is currently "Under construction". I'm migrating to a new version of my site building software. Lots of things are in a state of disrepair as a result (for example, footnote links aren't working). It's all part of the process of building in public. Most things should still be readable though.

Deserialize MiniJinja Values To Structs Via Serde JSON In Rust

This is just a snippet to get started with.

Code

pub fn get_subtree(&self, args: &[Value]) -> Vec<CollectionItem> {
        let original_json = json!(args[1]);
        let original_collection: Collection = serde_json::from_value(original_json).unwrap();
        dbg!(original_collection);

}