#I uplolded a folder (full of image) to Trunk. How do I access this file within my Yew HTML code?

10 messages · Page 1 of 1 (latest)

rotund bison
#

For these files

#

(the pictures are in the "Clubs" folder)

#

So

#

How am I supposed to access ..\Clubs\Clubs1 in my main.rs via a yew <img>?

#
mod elements;
use yew::prelude::*;

#[function_component(App)]
fn app () -> Html{
    html!{
        <img src = r"dist\Media\Cards\Clubs\Clubs1.png"/>
    }
}
fn main() {
    yew::Renderer::<App>::new().render();
}

``` main.rs
#

I uplolded a folder (full of image) to Trunk. How do I access this file within my Yew HTML code?

wispy pollen
ashen tendon
#

/ at the start of the path is the root of the website, same as itd be the root of the fs