Hey all, just looking for some advice. I’d like to do a WASM application, just generally like a calendar + notes app. I’d like it to work on mobile and desktop through the browser. It’ll be served through Actix with Diesel for the backend. For the “frontend” I was thinking egui or leptos.

I’d like to avoid any JavaScript, so thought SSR might be the best approach.

Any thoughts/pitfalls? Should I look at something else for the frontend?

Its a lot of working parts for a calendar + notes app, but this will be a testing ground to see if I can get it all going :S

  • blechlawine@feddit.org
    link
    fedilink
    English
    arrow-up
    2
    ·
    4 天前

    I would use leptos for a wasm app, but you would need to figure styling out yourself, cause afaik there aren’t any rellay usable ui frameworks for leptos yet

    You could also use htmx for the frontend and render the html entirely on the server, then you wouldn’t need a wasm build. For rendering on the server i like to use leptos’ view! macro. Although if you need heavy interactivity you would probably still need to write at least some js, even when using htmx

    • Matty_r@programming.devOP
      link
      fedilink
      arrow-up
      3
      ·
      4 天前

      I think I’m going to go this route - Leptos + HTMX. I’ll see how far this gets me without any JS. What type of interactivity do you think might require JS? I assume I should be able to do form validation etc without it?

      • blechlawine@feddit.org
        link
        fedilink
        English
        arrow-up
        1
        ·
        4 天前

        Depending on how powerful you want to make the calendar feature, that might require some amount of javascript. Things like dropdowns with more functionality than the standard select element, or autocomplete inputs, too. Generally anything that has some amount of client-side state, although many of them can easily be done with something like alpinejs or petitevue. Since form validation should be done on the server anyways and the html elements for inputs already have relatively powerful validation built in as well, form validation should not require any js.

        • Matty_r@programming.devOP
          link
          fedilink
          arrow-up
          2
          ·
          4 天前

          OK, that’s fine. Just means I’d need to think more about how stuff is implemented. I’m thinking like input fields for date and time selection etc. Could be an interesting challenge for sure.

          Surely its all been done before ha ha