Blog attempt 5
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

og description

+8 -1
+8 -1
src/post.rs
··· 142 142 let markup = html! { 143 143 // samp {( format!("{post:#?}") )} 144 144 h1.blog-head { (PreEscaped(post.title.clone() ))} 145 - @let subtitle = post.subtitle.unwrap_or("".to_string()); 145 + @let subtitle = post.subtitle.clone().unwrap_or("".to_string()); 146 146 span.blog-subhead { em { (subtitle) }} 147 147 hr.frontmatter; 148 148 p.blog-publish { ··· 159 159 script defer src="/static/js/footnotes.js" {} 160 160 161 161 meta property="og:title" content={(post.title) " — Jo's Blog"}; 162 + 163 + meta property="og:description" content={ 164 + (if let Some(subtitle) = post.subtitle { 165 + format!("{subtitle} — ") 166 + } else { "".to_string() }) 167 + "Posted on " (format_date(post.creation_datetime)) 168 + }; 162 169 }) ) 163 170 div.wrapper { 164 171 (navbar(endpoint))