#!/usr/bin/env -S cargo +nightly -Zscript ---cargo [package] edition = "2021" [dependencies] script-meditate = { path = "..", features = ["json"] } serde = { version = "1.0", features = ["derive"] } --- /*json { "test": 42 } */ fn main() { let value: Data = script_meditate::extract_json_frontmatter!(); dbg!(&value); assert_eq!(value.test, 42); } #[derive(Debug, serde::Deserialize)] struct Data { test: u8, }