diff options
Diffstat (limited to 'src/main.rs')
| -rw-r--r-- | src/main.rs | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/main.rs b/src/main.rs index 77f4fef..942b621 100644 --- a/src/main.rs +++ b/src/main.rs @@ -6,14 +6,15 @@ use crate::works::Works; mod works; fn main() -> Result<()> { + // new tera instance let tera = Tera::new("templates/**/*.html")?; + // render index.html file let context = Context::new(); - let output = tera.render("index.html", &context)?; - std::fs::write("docs/index.html", output)?; + // render stories.html file let stories = works::stories::Stories::new_from_file(std::fs::File::open( std::path::PathBuf::from("stories.json"), )?); |
