Build presentation slides with Markdeep and present them right in your browser.
Also, check out markdeep-thesis and markdeep-diagram-drafting-board!
This repository contains copies of all dependencies (Markdeep, MathJax, and the webfonts used by the built-in themes) by design – it'll work offline (unless you include YouTube videos or something in your slides). You don't want to rely on wifi being available when and where you'll present – that's just asking for trouble.
Then simply...
demo.md.html
,Use the following keyboard shortcuts to steer your presentation. Press...
At the bottom of demo.md.html
, right before a bunch of essential JavaScript files are loaded, you'll find a set of options. Their default values (each of which is automatically applied if you omit the corresponding option) are:
<script>
markdeepSlidesOptions = {
aspectRatio: 16 / 9, // aspect ratio of your slides
theme: 'simple', // theme – "simple", "deepsea", "serif" or path of a stylesheet
fontSize: 28, // base font size, relative to slide display size
diagramZoom: 1.0, // markdeep diagram scaling factor
totalSlideNumber: false, // show total number of slides next to slide number?
progressBar: true, // show a presentation progress bar on each slide?
breakOnHeadings: false, // start a new slide not only on encountering "---", but also level 1 and 2 headings?
slideChangeHook: (oldSlide, newSlide) => {}, // function executed whenever the current slide changes, receives old and new slide number
modeChangeHook: (newMode) => {} // function executed whenever the mode changes, receives new mode, e.g. "draft" or "presentation"
};
</script>
Modify them to your liking, but don't decrease the font size too much (nobody wants to read novel-length slides). Additionally, you can tweak some aspects of each theme by overriding CSS variables – take a look at the relevant file in markdeep-slides/themes/
.
It's best to use Chrome for generating a PDF version of your slides – it respects the page size that's automatically specified in CSS based on your chosen aspect ratio (unlike all other browsers). In Chrome's print window, set "Margins" to "None" and make sure to keep the "Background graphics" option enabled.
In my experience, once you've dialled in this print configuration, you can run Chrome headlessly for future exports (you may need to boost the --virtual-time-budget
depending on the complexity of your slides):
chrome --headless --disable-gpu --print-to-pdf=demo.md.html.pdf --no-margins --virtual-time-budget=5000 demo.md.html
Here's a list of presentations that folks have built using this tool:
Got an idea on how to improve something? Ran into unexpected behavior? Found a bug? (Maybe even fixed that bug?)
Please file an issue or send a pull request! I'll be glad to take a look at it.
I'd love to hear from you (or take a peek at your slides) if you've used this tool in practice.
<span class="current-date"></span>
– markdeep-slides
takes care of the rest.font-size
s, margin
s, padding
s, width
s, height
s and other sizes are defined in terms of rem
, em
, or %
. This enables your elements to scale properly depending on screen size. So don't use px
, pt
, or mm
.vw
and vh
as size units – depending on the aspect ratio of your display and your slides, your slides will be letterboxed, so 100vh
might be larger than the width of your slides (the same goes for height). The actual slide width and height can be read from the CSS variables var(--slide-width)
and var(--slide-height)
, respectively.var
iables to keep your theme configurable (take a look at the existing themes to see some examples).body
selector as opposed to the .slide
selector. This prevents small gaps caused by rounding errors from showing up in exported PDFs..presenter-notes
class.If you know of an elegant way of fixing these, I'd very much appreciate a heads up.
vw
units in CSS, so it should scale as the viewport width changes. It does in all other browsers, anyway.webkitfullscreenchange
event does not fire in this situation. (Other browsers exit fullscreen mode upon refresh, making this a non-issue there.)invert()
filter to two selectors referring to elements that may contain each other, applies the filter to both elements separately, i.e. the filter cancels itself out. Other browsers do the "right" thing. This affects code snippets with line numbers when using the deepsea
theme.You may use this repository's contents under the terms of the BSD 2-Clause "Simplified" License, see LICENSE
.
However, the subdirectory markdeep-slides/lib/
contains third-party software with its own licenses: