@nvcook42/parser
v0.1.2
Published
## Installing toolchain
Downloads
2
Readme
Rust implementation of a Flux parser
Installing toolchain
Install Rust https://www.rust-lang.org/tools/install
Install wasm-pack
:
$ cargo install wasm-pack
See this for a hello world example of using Rust with WASM and npm.
Build WASM
Use wasm-pack
to build an npm package from the compiled wasm code.
$ cd internal/rust/parser
$ wasm-pack build
Link npm modules
This only needs to be done once to create symlinks that npm can use to consume the wasm npm package without publishing it.
$ cd internal/rust/parser/pkg
$ npm link
$ cd ../../site
$ npm link parser
Run in Browser
Test
Use cargo
$ cd internal/rust/parser
$ cargo test