Crates.io | wasm-rs-dbg |
lib.rs | wasm-rs-dbg |
version | 0.1.2 |
source | src |
created_at | 2021-02-05 17:06:29.01694 |
updated_at | 2021-02-20 23:12:53.95081 |
description | dbg! macro for WebAssembly environment |
homepage | |
repository | https://github.com/wasm-rs/dbg |
max_upload_size | |
id | 351182 |
size | 22,858 |
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.
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;
Licensed under either of