Skip to content

100pah/md2reveal

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

32 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

用markdonw写PPT(Translate md to reveal)

reveal-md更改而来

Modified from reveal-md

使用方式(Usage)

  • 安装

    • git clone
    • npm install
    • 定义命令(Define alias):
alias md2reveal="node /your-folder/md2reveal/bin/cli.js"
  • 开始编译(Compile):
md2reveal mySlides.md
  • 生成(Production):mySlides.html

  • 注意:资源文件(img/css/js...)须放到同级目录下的asset文件夹中。

Notice: put resource files (img/css/js...), if exists, in the directory named asset in the level of the md file.

  • 监视文件改变自动编译(Watch, if you wish)

加入-w参数:

using -w

md2reveal -w mySlides.md

  • 使用自定义 theme(Customize theme)

md2reveal --theme '../../theme/folder/path' mySlides.md

语法

参见:https://github.com/100pah/md2reveal/blob/master/demo/md-slides.md

Markdown中一些额外的使用提示(Extra Usage Hints of Markdown)

每页中的分步显示(Fragment)

{0|阿斯顿发送到}
{1|撒旦法撒旦}

or

<div class="fragment" data-fragment-index="0">阿斯顿发送到</div>
<div class="fragment" data-fragment-index="1">撒旦法撒旦</div>

嵌入iframe(Embed iframe)

~[70%*500](http://echarts.baidu.com/doc/example/line1.html)

会被转换为(will be translate to):

<iframe style="width: 70%; height: 500px" data-md2r-src="./asset/ec-next/test/area.html">
</iframe>

宽度高度可以省略(width and height can be omitted):

~[*500](http://echarts.baidu.com/doc/example/line1.html)
~[70%*](http://echarts.baidu.com/doc/example/line1.html)
~[](http://echarts.baidu.com/doc/example/line1.html)

将src放在data-src下意思是,在每页或每fragment进入时候加载iframe中内容。

Put src in data-src attribute to enable auto reload iframe when page changed or fragment changed

写注释(Write note)

Note:
这里的内容在注释中

使用背景图片(Use background image)

reveal.js 原生支持。(Supported by reveal.js internally.)

<!--.slide: data-background="./asset/theme/img/end.png" -->

Reveal演示的一些提示(Presentation Hints)

revealjs 演示的时候:

  • s键,能开启后台看注释的模式。
  • f键,全屏。

Try pressing s, f when presenting.

demo

https://github.com/100pah/slides/tree/master/segment-fault

Releases

No releases published

Packages

No packages published