Skip to content →

Presentations as code

Introduction

I need to present quite a bit in my current role as an architect. I try to lay out a common goal, make sure it is correct, and get the team on board and take their part of the responsibility. I want to extend my NeoVim setup to create my presentations. This blog post discusses some tools to achieve this and my experience with them.

Plugin requirement

I use the Lazy plugin manager, but all the plugins can also be used in Packer. I try to use only plugins written in Lua. I see no scenario, at the moment, where I will be moving to regular VIM and losing the Lua plugin capabilities.

Some of my requirements are:

  • The plugin should be able to present the slides visually.
  • Written in Lua
  • Basic layout capabilities include lists, images, and some transition animation.

Present

The first Neovim plugin I tried was present.neovim. However, I did not get it to work, and the documentation was unclear.

Marp

Marp (Markdown Presentation Ecosystem) is a powerful tool that converts Markdown documents into presentation slides.

One of Marp's key advantages is its simplicity—if you know Markdown, you can create presentations. It supports themes and custom CSS and can export to various formats, including PDF and PowerPoint.

For Marp, I use the https://github.com/mpas/marp-nvim plugin. This plugin enabled me to automatically update a presentation as I edited the slides. The only external dependency is the Marp CLI.

Example

This example shows a multipage presentation. New slides are added with ---

# Introduction

- About the project
- Roadmap
- Definition of done

---

# Way of working

- No separation between *dev* and *ops*

<!-- notes: This is a speaker note. It will not appear on the slide. -->

This example will create a PowerPoint presentation with two slides. The last slide will include speaker notes.

In Neovim I can execute the following command: MarpStart which will use the Marp CLI and show the following page:

Here, I can download the presentation in different formats. I can also click the one.md itself and get a live updated presentation in my browser as I work on the presentation.

GitHub actions

There are GitHub actions that can output the markdown to various formats, e.g, powerpoint and pdf. Like the screenshot above. I have created a short demo repo at https://github.com/fredrkl/marp-demo where you can see the setup. It also uses GitHub pages to provide artifacts links.

Lessons learned

Marp, or creating slides using markdown, is quick and easy. It has support for styling and images. However, when you need more complex features such as:

  • Live collaboration updates
  • Easy sharing to non-programmers
  • Complex layout

A more dedicated tool such as PowerPoint is better.

Summary

Creating presentations in Neovim using markdown-based tools like Marp offers a streamlined approach for developers who prefer working in their familiar editor environment. While these tools excel at simple, clean presentations with basic styling and image support, they may not be the best choice for complex collaborative scenarios or when working with non-technical team members.

Published in architecture productivity tips&tricks

Subscribe
Notify of
guest

0 Comments
Oldest
Newest Most Voted
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x