Attribute Macro vertigo::main

source ·
#[main]
Expand description

Marco that marks an entry point of the app

Note: Html, head and body tags are required by vertigo to properly take over the DOM

use vertigo::prelude::*;

#[vertigo::main]
fn app() -> DomNode {
    dom! {
        <html>
            <head/>
            <body>
                <div>"Hello world"</div>
            </body>
        </html>
    }
}