Skip to content

Latest commit

 

History

History
36 lines (22 loc) · 1.61 KB

README.md

File metadata and controls

36 lines (22 loc) · 1.61 KB

wasm-tools-go

build status pkg.go.dev

WebAssembly + WASI tools for Go

About

This repository contains code to adapt WIT (Wasm Interface Type) files into Go, with the goal of accelerating the Go implementation of WASI Preview 2.

WIT → JSON

This package can decode a JSON representation of a fully-resolved WIT file. Serializing WIT into JSON requires wasm-tools v1.0.42 or higher. To convert a WIT file into JSON, run wasm-tools with the -j argument:

wasm-tools component wit -j example.wit

This will emit JSON on stdout, which can be piped to a file or another program.

wasm-tools component wit -j example.wit > example.wit.json
wasm-tools component wit -j example.wit > wit-bindgen-go

License

This project is licensed under the Apache 2.0 license with the LLVM exception. See LICENSE for more details.

Contribution

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in this project by you, as defined in the Apache-2.0 license, shall be licensed as above, without any additional terms or conditions.