console_log: a crate for logging to the browser's console from wasm apps
I just finished up a small crate to log to the browser's console from wasm apps using rust's standard log facilities.
Edit: and I just found https://crates.io/crates/wasm-bindgen-console-logger that does the same thing, published 2 hours before mine...
Posted Jan 1, 2019, 5:18 AM UTC
I use ferns function logger pass in a closure that calls stdweb's console!(log, ) macro so I can use info!, debug! as usual.
Interesting approach. I wasn't aware of fern. I'll add a link to this in the readme in case users want more flexibility. Maybe I should export a
log()function that can be passed directly to fern. 🤔Edit: implemented in v0.1.2