[!INFO] These bindings are not intended to be used directly, use the associated SDK instead.
- Install the emscripten toolchain:
brew install emscripten.emscriptenis used to compile from Rust to WebAssembly. - Install LLVM:
brew install llvm, and then follow the instructions to add it to your PATH. Emscripten depends on LLVM's Clang (as opposed to Apple's Clang).
yarn: Installs all dependencies (required before building)yarn build: Build a release version of the WASM bindings for the current platformyarn lint: Run cargo clippy and fmt checksyarn format:check: Check formatting of integration testsyarn typecheck: Run typecheck on integration testsyarn test: Run cargo test withwasm32-unknown-unknowntargetyarn test:integration: Run integration tests using vitest
These commands require Homebrew and llvm to be installed. See above.
yarn check:macos: Run cargo checkyarn lint:macos: Run cargo clippy and fmt checksyarn build:macos: Build a release version of the WASM bindingsyarn test:integration:macos: Run integration tests using vitest
To release a new version of the bindings, update the version in package.json with the appropriate semver value. Once merged, manually trigger the Release WASM Bindings workflow to build and publish the bindings.