logo
努力加载中 ……

幻灯片

原创Starzkg12/19/2021, 8:14:03 AM2371 分钟

Let the Markdown file in your VuePress site support presentation.

Configuration

module.exports = {
  plugins: [
    [
      "markdown-enhance",
      {
        // Enable presentation
        presentation: true,
      },
    ],
  ],
};

This plugin is using reveal.jsopen in new window to support this feature.

You can also pass an object for configuration.

presentation.plugins receives an array of strings, allowing you to freely config whether to enable some preset plugins.

TIP

Acceptable plugins are:

  • "highlight"
  • "math"
  • "search"
  • "notes"
  • "zoom"

You can also use presentation.revealConfig set configuration options passed to Reveal.js globally.

Reveal.js also provides more pluginsopen in new window. If you need a specific plugin, please submit a Feature Requestopen in new window on GitHub.

Syntax

  • Use --- to split slides
  • Use -- to split the slides second time (vertical display)
@slidestart [theme]

<!-- slide1 -->

---

<!-- slide2 -->

---

<!-- slide3 -->

@slideend

Theme available(replace [theme] with them):

  • auto (Default)
  • black
  • white
  • league
  • beige
  • sky
  • night
  • serif
  • simple
  • solarized
  • blood
  • moon

For details, see Themes demo.

Demo

Please see Presentation Demo

Options

You can set reveal to pass options to reveal.js per page in frontmatter, you can also set presentation in plugin options to set reveal.js globally.

For more options, see reveal.js configopen in new window. For more usage, see reveal.js documatationopen in new window