Marp is a tooling to create presentations based on markdown and css.

TL;DR

VSCode settings

First, search for “Marp” in the extensions tab and install Marp for VSCode from marp-team

Preview Button

Screenshot of VSCode with a yellow box around a top right icon. The icon looks like an open book with a magnifying glass. With the preview button you can have a side by side view of your markdown and the presentation slides. The changes you make in your markdown are shown in the slides in real-time.

Generate the presentation manually

Screenshot of VSCode with a yellow box around an icon in the top right corner. The icon looks like two overlapping right triangles. With the “Marp Command Button” you can enter an interactive save dialog to export your presentation.

Using style sheets

If you want to customize the presentation via a style sheet, you need to be aware on how to register your custom theme via the plugin and how to use it in your presentation markdown file.

Create your theme.css and declare the theme name in the first line: /* @theme yourthemename */

Configure which theme your presentation.md should use via the global directive:

---
marp: true
theme: yourthemename
---

Registering your style sheets

  • Open the Settings (File -> Preferences -> Settings) and search for “marp” to display the Marp plugin settings
  • Under “Markdown > Marp: Themes” you need to register your themes to make them available by adding the style sheet’s name.

Alternative to adjusting settings by hand

In your Marp project, you can check in a .vscode folder with a settings.json. In there, you can register your themes:

{
    "markdown.marp.themes": [
        "relative/path/to/your/theme1.css",
        "relative/path/to/your/theme2.css"
    ]
}

How do I know my theme works?

If your theme is not registered correctly, VSCode will show a hint in the presentation.md file like “the specified theme is not recognized by Marp for VSCode”. If your theme is registered, you will see changes take effect immediately in the markdown preview.