#log #web #print

no-std web-log

Simple utilities to write into browser's console

1 stable release

1.0.1 Dec 12, 2021
1.0.0 Feb 18, 2021

#684 in WebAssembly

Download history 1/week @ 2024-11-13 3/week @ 2024-11-20 5/week @ 2024-11-27 53/week @ 2024-12-04 26/week @ 2024-12-11 5/week @ 2024-12-18 6/week @ 2025-01-01 34/week @ 2025-01-08 8/week @ 2025-01-15 3/week @ 2025-01-22 37/week @ 2025-02-05 45/week @ 2025-02-12 6/week @ 2025-02-19 4/week @ 2025-02-26

92 downloads per month
Used in 3 crates (2 directly)

BSL-1.0 license

10KB
217 lines

web-log

Rust Crates.io Documentation

Minimal wrapper over browser console to provide printing facilities

Features:

  • std - Enables std::io::Write implementation.

Usage

use web_log::{ConsoleType, Console};

use core::fmt::Write;

let mut writer = Console::new(ConsoleType::Info);
let _ = write!(writer, "Hellow World!");
drop(writer); //or writer.flush();

web_log::println!("Hello via macro!");
web_log::eprintln!("Error via macro!");

lib.rs:

Minimal wrapper over browser console to provide printing facilities

Features:

  • std - Enables std::io::Write implementation.

Usage

use web_log::{ConsoleType, Console};

use core::fmt::Write;

let mut writer = Console::new(ConsoleType::Info);
let _ = write!(writer, "Hellow World!");
drop(writer); //or writer.flush();

web_log::println!("Hello via macro!");
web_log::eprintln!("Error via macro!");

Dependencies

~0.7–1.3MB
~27K SLoC