All Projects → vascokk → fullstack-rust

vascokk / fullstack-rust

Licence: Apache-2.0 license
Reference implementation of a full-stack Rust application

Programming Languages

rust
11053 projects

Projects that are alternatives of or similar to fullstack-rust

Wasmer Postgres
💽🕸 Postgres library to run WebAssembly binaries.
Stars: ✭ 245 (+528.21%)
Mutual labels:  webassembly, wasm
wasm-ops
Chart of WebAssembly Instructions
Stars: ✭ 46 (+17.95%)
Mutual labels:  webassembly, wasm
Rust Yew Realworld Example App
Exemplary real world app built with Rust + Yew + WebAssembly
Stars: ✭ 249 (+538.46%)
Mutual labels:  webassembly, wasm
Awesome Wasm Langs
😎 A curated list of languages that compile directly to or have their VMs in WebAssembly
Stars: ✭ 2,966 (+7505.13%)
Mutual labels:  webassembly, wasm
jasper
🧳 Single-binary packaging for Ruby applications that supports native and Wasm targets
Stars: ✭ 29 (-25.64%)
Mutual labels:  webassembly, wasm
Wapm Cli
📦 WebAssembly Package Manager (CLI)
Stars: ✭ 236 (+505.13%)
Mutual labels:  webassembly, wasm
bounce
The uncomplicated Yew State management library
Stars: ✭ 43 (+10.26%)
Mutual labels:  wasm, yew
Wasm Worker
Move a WebAssembly module into its own thread
Stars: ✭ 215 (+451.28%)
Mutual labels:  webassembly, wasm
ugo-compiler-book
📚 µGo语言实现(从头开发一个迷你Go语言编译器)[Go版本+Rust版本]
Stars: ✭ 996 (+2453.85%)
Mutual labels:  webassembly, wasm
rocket-yew-starter-pack
Example boilerplate for websites in pure Rust
Stars: ✭ 77 (+97.44%)
Mutual labels:  wasm, yew
Wasm By Example
Wasm By Example is a website with a set of hands-on introduction examples and tutorials for WebAssembly (Wasm)
Stars: ✭ 226 (+479.49%)
Mutual labels:  webassembly, wasm
wasm-linker-js
A simple WebAssembly Linker in JavaScript
Stars: ✭ 14 (-64.1%)
Mutual labels:  webassembly, wasm
Asm Dom
A minimal WebAssembly virtual DOM to build C++ SPA (Single page applications)
Stars: ✭ 2,604 (+6576.92%)
Mutual labels:  webassembly, wasm
Wasmtime Go
Go WebAssembly runtime powered by Wasmtime
Stars: ✭ 239 (+512.82%)
Mutual labels:  webassembly, wasm
Pont
An online board game in Rust and WebAssembly
Stars: ✭ 218 (+458.97%)
Mutual labels:  webassembly, wasm
Prism
Build frontend web apps with Ruby and WebAssembly
Stars: ✭ 251 (+543.59%)
Mutual labels:  webassembly, wasm
Artichoke
💎 Artichoke is a Ruby made with Rust
Stars: ✭ 2,557 (+6456.41%)
Mutual labels:  webassembly, wasm
Vue
The progressive framework for WebAssembly applications.
Stars: ✭ 211 (+441.03%)
Mutual labels:  webassembly, wasm
material-yew
Yew wrapper for Material Web Components
Stars: ✭ 116 (+197.44%)
Mutual labels:  wasm, yew
wasmsign2
PoC implementation of the WebAssembly Modules Signatures proposal.
Stars: ✭ 18 (-53.85%)
Mutual labels:  webassembly, wasm

Full-stack Rust with WebAssembly

Look Ma, No JavaScript !!!

img.png

My very first Rust project (implementation of the "Connect 5" game), I used as a learning tool.

My goal was to create some sort of a "reference implementation" of a Fullstack Rust application. Hopefully you will find it useful :). Here you can find how to:

Client:

  • build Web client in Rust, without a single line of JavaScript, using Yew WebAssembly framework
  • use yew-router for navigation between pages
  • use multithreading components, communicating by "message passing" with Yew Agents
  • use Yew StorageService to keep session data
  • utilise a CSS framework (Bulma)

Server:

  • Use Actix Web web framework to implement REST API
  • Diesel ORM with SQLite as default DB
  • Session cookies
  • Integration testing for the REST API
  • Mocking functions (db calls) in unit tests

Usage:

Install trunk and build the client:

cd client
cargo install trunk wasm-bindgen-cli
trunk build -d ../server/static/ 

Start the server:

cd server
cargo run --package connect5-rust --bin connect5-rust

Open http://127.0.0.1:8088/ in your browser. Open a second session in another browser for player #2.

There are still few things that need to be improved/fixed, but the project served it's purpose (for me, at least) and is useful as it is, so I'll probably won't be fixing them. Feel free, however, to do so and may be create some PR(s) :)

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].