use dioxus::prelude::*;

use crate::components::{BlogPost, TagNav};



/// Blog page
#[component]
pub fn Post(slug: ReadSignal<String>) -> Element
{
   // Create a copy of the current slug to detect changes.
   let url_slug = use_signal(|| slug());

   rsx!
   {
      main
      {
         class: "blog_style",
         div
         {
            class: "page_content",

            BlogPost
            {
               slug: url_slug
            }

            TagNav { }
         }
      }
   }
}
