stuartlynn / Component_model_example

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Component model example

This repo is to explore using the component model in wasm through rust to deliver functionality to web apps.

It uses

  • WIT to define an interface
  • cargo-component to build it in to a wasm component
  • jco to produce bindings for that component for JS
  • svelte as a framework

Building the wasm component

The wasm component can be built using

pnpm build_wasm 

this will produce the wasm file and the JS bindings

Runnning the app

pnpm dev 

About


Languages

Language:JavaScript 72.2%Language:TypeScript 8.8%Language:Rust 8.5%Language:Svelte 5.3%Language:HTML 3.3%Language:Python 1.9%