Skip to content

Instantly share code, notes, and snippets.

Avatar

Yuki Hattori yhatt

  • Japan
  • 01:03 (UTC +09:00)
  • Twitter @y_hatt
View GitHub Profile
@yhatt
yhatt / hide-slides-plugin.js
Last active August 17, 2022 14:23
Marp hide slides plugin example
View hide-slides-plugin.js
const marpHideSlidesPlugin = (md) => {
md.marpit.customDirectives.local.hide = (value) => ({
hide: value === 'true',
})
md.core.ruler.after(
'marpit_directives_apply',
'marpit_hide_slides',
(state) => {
let withinSlide = false
@yhatt
yhatt / transition-showcase.md
Last active May 29, 2022 02:58
Marp CLI experimental transition showcase
@yhatt
yhatt / diagrams.md
Last active March 22, 2023 09:12
Marp diagram plugin example (Powered by kroki.io)
View diagrams.md
marp theme
true
default

Marp diagram plugin example

Powered by kroki.io

@yhatt
yhatt / transitions.md
Created August 27, 2021 21:00
Experimental transitions for Marp CLI
View transitions.md
title _class theme style marp
Marp CLI experimental transitions
lead gaia
gaia
pre { font-size: 60px; }
true
View command
npm i @marp-team/marp-cli @marp-team/marp-core markdown-it-admon
npx marp --engine engine.js slide.md
@yhatt
yhatt / marp.md
Created September 16, 2019 19:07
Marp Next example
View marp.md
marp
true

Marp

h:250

Markdown presentation ecosystem
@yhatt
yhatt / gaia.md
Last active August 8, 2021 13:37
Gaia theme example (for Marp Next)
View gaia.md
marp theme
true
gaia

Gaia theme

[Marp Next] slide theme

@yhatt
yhatt / uncover.md
Last active April 5, 2019 17:08
Uncover theme example
View uncover.md
theme paginate _paginate title header footer
uncover
true
false
UNCOVER THEME
UNCOVER THEME
A brand-new theme of Marp core
@yhatt
yhatt / mkgif.sh
Created December 23, 2017 07:17
mkgif
View mkgif.sh
#!/bin/sh
usage() {
echo "Usage: ${0##*/} [-o output] [-r framerate] [-f ffmpeg-filter] [-s width:height] input" 1>&2
echo ""
echo "Examples:"
echo " ${0##*/} foo.mp4 : Output GIF to foo.gif"
echo " ${0##*/} -o bar.gif foo.mp4 : Output GIF to bar.gif"
echo " ${0##*/} -r 10 foo.mp4 : Set framerate as 10"
echo " ${0##*/} -s 320:-1 foo.mp4 : Resize width to 320px with fixed aspect-ratio"