BitMask Core
Core functionality for the BitMask wallet - https://bitmask.app
BitMask is a bitcoin wallet and a browser extension for accessing decentralized web applications on the Bitcoin blokchain. It is designed to support UTXO based smart contracting protocols such as RGB, with planned support for Omni layer, TARO and many others.

Uses
Build
This should work with either wasm-pack, trunk, or x86-64.
Some environment variables may be needed in order to compile on macos-aarch64, for more, see this.
If there are issues compiling, be sure to check you're compiling with the latest Rust version.
To build this as a NodeJS module, use: wasm-pack build --release --target bundler
Test
- Lint against wasm32:
cargo clippy --target wasm32-unknown-unknown
- Run tests in browser:
TEST_WALLET_SEED="replace with a 12 word mnemonic for a wallet containing testnet sats" wasm-pack test --headless --chrome
Run
To run the bitmaskd node with REST server, either for testing the web wallet, or simply for increased privacy:
cargo install --features=server --path .
Then run bitmaskd
.
Development
Parts of this application are built with conditional compilation statements for wasm32 support. This is a helpful command for checking linting and correctness while also developing on desktop platforms:
cargo clippy --target wasm32-unknown-unknown --no-default-features --release