Intro

We can specify the format as revealjs to make a presentation.

Fragments

Fragments can be used to animate elements on a slide. Fragment order can be defined using fragment-index.

  • Fade in
  • Fade out
  • Fade in, then out
  • Slide up while fading in

Code-highlighting

If displaying a code block, lines can be highlighted in a sequential fashion using code-line-numbers.

library(ggplot2)

ggplot(mpg, aes(x = hwy, y = cty, color = cyl)) +
  geom_point(alpha = 0.5, size = 2) +
  scale_color_viridis_c() +
  theme_minimal()

Mermaid charts

Diagrams can be embedded using Mermaid which has a great live editor!

Hard edge

Round edge

Decision

Result one

Result two