Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/ilaborie/jug-summer-camp-24

Et si on écrivait nos Web Components en Rust?
https://github.com/ilaborie/jug-summer-camp-24

Last synced: about 2 months ago
JSON representation

Et si on écrivait nos Web Components en Rust?

Awesome Lists containing this project

README

        

# How about writing our Web Components in Rust?

## Requirements

* NodeJS 20+, see [Download Node](https://nodejs.org/en/download/package-manager)
* Rust development tools installed, see [rustup](https://rustup.rs/)
* Extra rust tools:
* [`wasm-pack`](https://github.com/rustwasm/wasm-pack) for building WASM
* [`dioxus-cli`](https://dioxuslabs.com/learn/0.5/getting_started) the [Dioxus](https://dioxuslabs.com/) companion CLI
* [`cargo-watch`](https://github.com/watchexec/cargo-watch) to watch an rebuild the code

Rust tools can be installed with `cargo install `
or with `cargo binstall ` if you have [`cargo-binstall`](https://github.com/cargo-bins/cargo-binstall) installed

This project use [mise](https://mise.jdx.dev/) to set requirements

To install node dependencies, use `npm ci`

Then you can build WASM in `rust-wc/` and `dioxus-wc/` with `wasm-pack build --release --no-pack --target web`

## Try it

Just need to run `mise run dev` or `npm run watch & npm run dev` to launch the DEV mode.

Then open