mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-06-14 16:51:03 +00:00
add wasm support (#700)
* get started * make it work again * make it compile again * Use async-wasm-feature of jsonrpsee from the master branch * Ensure we enable JS feature of getrandom for the wasm target * Update subxt/src/lib.rs * update jsonrpsee * fix CI * cargo fmt * fix wasm test * fix grumbles * exclude wasm-tests from workspace To avoid leaking `jsonrpsee-web` feature into the workspace Co-authored-by: Igor Matuszewski <xanewok@gmail.com>
This commit is contained in:
@@ -140,6 +140,13 @@ use tokio as _;
|
||||
|
||||
pub use subxt_macro::subxt;
|
||||
|
||||
// Used to enable the js feature for wasm.
|
||||
#[cfg(target_arch = "wasm32")]
|
||||
pub use getrandom as _;
|
||||
|
||||
#[cfg(all(feature = "jsonrpsee-ws", feature = "jsonrpsee-web"))]
|
||||
std::compile_error!("Both the features `jsonrpsee-ws` and `jsonrpsee-web` are enabled which are mutually exclusive");
|
||||
|
||||
pub mod blocks;
|
||||
pub mod client;
|
||||
pub mod config;
|
||||
|
||||
Reference in New Issue
Block a user