3 releases

0.1.2 Feb 20, 2021
0.1.1 Feb 20, 2021
0.1.0 Feb 5, 2021

#594 in WebAssembly

Download history 7016/week @ 2024-11-30 2944/week @ 2024-12-07 3974/week @ 2024-12-14 353/week @ 2024-12-21 1743/week @ 2024-12-28 5036/week @ 2025-01-04 9049/week @ 2025-01-11 4469/week @ 2025-01-18 3264/week @ 2025-01-25 10715/week @ 2025-02-01 6553/week @ 2025-02-08 3649/week @ 2025-02-15 3536/week @ 2025-02-22 5082/week @ 2025-03-01 4167/week @ 2025-03-08 4426/week @ 2025-03-15

18,847 downloads per month
Used in 6 crates (3 directly)

MIT/Apache

9KB
56 lines

dbg! for wasm32

Crate API Chat

This micro-crate provides a drop-in replacement for std::dbg macro that logs to console when compiled for wasm32-unknown-unknown and falls back to std::dbg on all other platforms.

Usage

Include this dependency in your Cargo.toml:

[dependencies]
wasm-rs-dbg = "0.1.2"

Then, in files where you want to use WebAssembly-enabled logging to console, use this import:

use wasm_rs_dbg::dbg;

License

Licensed under either of

Dependencies

~0–2.3MB
~42K SLoC