legible 0.5.0

A Rust port of Mozilla's Readability.js for extracting readable content from web pages
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
/// Emits a structured debug event when the `tracing` feature is enabled.
macro_rules! debug_log {
    (@bool $debug:expr, $($arg:tt)*) => {
        if $debug {
            #[cfg(feature = "tracing")]
            tracing::debug!(target: "legible::readability", "{}", format_args!($($arg)*));
        }
    };
    ($self:ident, $($arg:tt)*) => {
        if $self.options.debug {
            #[cfg(feature = "tracing")]
            tracing::debug!(target: "legible::readability", "{}", format_args!($($arg)*));
        }
    };
}
pub(crate) use debug_log;