// momentum

+0β˜… Β· 0 issues Β· 2w

// why it's here

  • Active: last commit today
  • Built almost entirely by one person
  • Health 90/100 with only 44 stars
  • 6 releases in the last 90 days

// how to help

// readme

Wardite

A pure-ruby webassembly runtime.

  • Fully typed by RBS (with the aid of rbs-inline)
  • WASI (p1) support

Supported Instructions

ref: https://webassembly.github.io/spec/core/binary/instructions.html

  • Control Instructions
  • Parametric Instructions
  • Variable Instructions
  • Table Instructions
  • Memory Instructions (except data.drop)
  • Numeric Instructions (0x41 ... 0xC4)
  • Numeric Instructions (0xFC Operations)
  • Reference Instructions
  • Vector Instructions
  • end 0x0B

Installation

Install the gem and add to the application’s Gemfile by executing:

$ bundle add wardite

If bundler is not being used to manage dependencies, install the gem by executing:

$ gem install wardite

Usage

  • In your ruby code, instanciate Wardite runtime:
require "wardite"

path = ARGV[0]
method = ARGV[1]
args = ARGV[2..-1] || []

instance = Wardite::new(path: path)
if !method && instance.runtime.respond_to?(:_start)
  instance.runtime._start
else
  instance.runtime.call(method, args)
end
  • Wardite bundles wardite cli command:
Read the full README on GitHub β†—