slide

Macro slide 

Source
macro_rules! slide {
    ($($command:expr),* $(,)?) => { ... };
}
Expand description

Defines a slide and shows it.

Takes any number of crossterm::Commands as arguments.

ยงExamples

use clp::{crossterm, slide, TypewriterPrint, TypewriterPrintStyledContent};
use crossterm::style::{Print, Stylize};
use std::time::Duration;

slide!(
    TypewriterPrint("Welcome to my presentation on ", Duration::from_millis(25)),
    TypewriterPrintStyledContent(
        "command line presentations".bold(),
        Duration::from_millis(50),
    ),
    Print("."),
)
.expect("the first slide should appear");

slide!(TypewriterPrint(
    "\n...there isn't much content on these slides.",
    Duration::from_millis(25),
))
.expect("the second slide should appear");