Rename the Root component to App

This commit is contained in:
Paul van Tilburg 2020-07-17 11:40:04 +02:00
parent b96ad9ecbd
commit f119d1ac38
Signed by: paul
GPG Key ID: C6DE073EDA9EEC4D
2 changed files with 4 additions and 4 deletions

View File

@ -1,13 +1,13 @@
use yew::prelude::*; use yew::prelude::*;
pub struct Root; pub struct App;
impl Component for Root { impl Component for App {
type Message = (); type Message = ();
type Properties = (); type Properties = ();
fn create(_props: Self::Properties, _complink: ComponentLink<Self>) -> Self { fn create(_props: Self::Properties, _complink: ComponentLink<Self>) -> Self {
Root App
} }
fn update(&mut self, _msg: Self::Message) -> ShouldRender { fn update(&mut self, _msg: Self::Message) -> ShouldRender {

View File

@ -6,5 +6,5 @@ use wasm_bindgen::prelude::*;
#[wasm_bindgen(start)] #[wasm_bindgen(start)]
pub fn run_app() { pub fn run_app() {
yew::start_app::<components::Root>(); yew::start_app::<components::App>();
} }