You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

35 lines
838 B
Rust

use yew::prelude::*;
use yew_styles::layouts::{
container::{Container, Direction, Wrap},
item::{Item, ItemLayout},
};
pub struct Home;
impl Component for Home {
type Message = ();
type Properties = ();
fn create(_: Self::Properties, _: ComponentLink<Self>) -> Self {
Home {}
}
fn update(&mut self, _: Self::Message) -> ShouldRender {
false
}
fn change(&mut self, _: Self::Properties) -> ShouldRender {
false
}
fn view(&self) -> Html {
html! {
<Container direction=Direction::Row wrap=Wrap::Wrap class_name="content">
<Item layouts=vec!(ItemLayout::ItXs(12), ItemLayout::ItM(8)) class_name="home-greeting">
<h1>{"Welcome to my website"}</h1>
</Item>
</Container>
}
}
}