Render the head for the page.

This commit is contained in:
Tom Alexander
2023-10-23 21:51:15 -04:00
parent 2b6f86d4e9
commit 178ce877bc
9 changed files with 126 additions and 9 deletions

View File

@@ -59,4 +59,12 @@ impl Config {
pub(crate) fn get_output_directory(&self) -> PathBuf {
self.get_root_directory().join("output")
}
pub(crate) fn use_relative_paths(&self) -> bool {
self.raw.use_relative_paths.unwrap_or(true)
}
pub(crate) fn get_web_root(&self) -> Option<&str> {
self.raw.web_root.as_deref()
}
}

View File

@@ -7,6 +7,8 @@ pub(crate) struct RawConfig {
site_title: String,
author: Option<String>,
email: Option<String>,
pub(super) use_relative_paths: Option<bool>,
pub(super) web_root: Option<String>,
}
impl Default for RawConfig {
@@ -15,6 +17,8 @@ impl Default for RawConfig {
site_title: "My super awesome website".to_owned(),
author: None,
email: None,
use_relative_paths: None,
web_root: None,
}
}
}