• Venator@lemmy.nz
    link
    fedilink
    English
    arrow-up
    1
    ·
    edit-2
    4 days ago

    Can browsers run rust in the front end instead of javascript, or is it limited to build time and backend stuff?

    • sushibowl@feddit.nl
      link
      fedilink
      English
      arrow-up
      1
      ·
      4 days ago

      Sort of, browsers can run rust code through webassembly. But i dont think this is a full replacement for JavaScript as of yet.

      • sugar_in_your_tea@sh.itjust.works
        link
        fedilink
        English
        arrow-up
        1
        ·
        4 days ago

        Yeah, you need to have some JS to manipulate graphics, so the Rust web frameworks have a JS shim to do that and communicate with the WebAssembly Rust code as necessary. It works surprisingly well tho.