#logging #dioxus #logging-tracing #log

dioxus-logger

A logging utility to provide a standard interface whether you're targetting web desktop, fullstack, and more

9 unstable releases

0.5.1 May 13, 2024
0.5.0 Apr 17, 2024
0.4.1 May 8, 2023
0.3.0 Nov 10, 2022
0.1.2 Nov 5, 2022

#111 in Debugging

Download history 1439/week @ 2024-08-05 1285/week @ 2024-08-12 1345/week @ 2024-08-19 1773/week @ 2024-08-26 1728/week @ 2024-09-02 1620/week @ 2024-09-09 2216/week @ 2024-09-16 2079/week @ 2024-09-23 1856/week @ 2024-09-30 1578/week @ 2024-10-07 2190/week @ 2024-10-14 2500/week @ 2024-10-21 2052/week @ 2024-10-28 1484/week @ 2024-11-04 1484/week @ 2024-11-11 1553/week @ 2024-11-18

6,918 downloads per month
Used in 9 crates

MIT license

6KB

📡 Dioxus Logger 🛰️

A logging utility to provide a standard interface whether you're targetting web, desktop, fullstack, and more.


dioxus-logger is a basic cross-platform facade for logging in Dioxus that uses the tracing crate.

use dioxus::prelude::*;
use dioxus_logger::tracing::{Level, info};
 
fn main() {
  dioxus_logger::init(Level::INFO).expect("logger failed to init");
  launch(App);
}

#[component]
fn App() -> Element {
  info!("App rendered");
  rsx! {
    p { "hi" }
  }
}

Platform Support

Dioxus logger will eventually support every target that Dioxus does. Currently mobile and TUI are not supported.

Installation

You can add dioxus-logger to your application by adding it to your dependencies.

[dependencies]
dioxus-logger = "0.5"

License

This project is licensed under the MIT license.

Every contribution intentionally submitted for inclusion in dioxus-logger by you, shall be licensed as MIT, without any additional terms or conditions.

Dependencies

~1.3–1.8MB
~27K SLoC