0.1.1 • Published 6 years ago

crypto-wasm v0.1.1

Weekly downloads
3
License
MIT
Repository
github
Last release
6 years ago

crypto-wasm

Dependencies

Make sure you have rust installed in your environment. follow this link: https://www.rust-lang.org/en-US/install.html to install rust toolchains.

如果你是中国用户, 执行

cat > $HOME/.cargo/config << EOF
[source.crates-io]
registry = "https://github.com/rust-lang/crates.io-index"
replace-with = 'ustc'
[source.ustc]
registry = "git://mirrors.ustc.edu.cn/crates.io-index"
EOF

然后

curl https://sh.rustup.rs -sSf | sed "s/https:\/\/static.rust-lang.org\/rustup\/dist/https:\/\/mirrors.ustc.edu.cn\/rust-static\/rustup\/dist/g" | sh

And then install the wasm-pack:

cargo install wasm-pack

And then use nightly rust

rustup default nightly

Build

wasm-pack init -t nodejs

Benchmark

  • yarn
  • node bench/{md5|sha256}