webpro / reveal-md

reveal.js on steroids! Get beautiful reveal.js presentations from any Markdown file

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Different rendering of slides with `--watch` and `--static`

renefritze opened this issue · comments

Using reveal-md@5.3.2 and it looks like the --template arg is ignored when used together with --watch.

reveal-md slides/myfile.md --watch

produces the same look as

reveal-md slides/myfile.md --watch --template slides/template.html

while

reveal-md slides/myfile.md --static docs --template slides/template.html

produces the expected look for docs/index.html.

Is this a bug or am I doing something wrong?

Not sure what's going on, for me it works just fine. Watch mode is active with a custom template.

So I've tried to confirm this for me with reveal-md@5.3.3. I still see the difference. However I now realized this actually just is that the browser displays the content with a larger font size for whatever reason.
Happens across browsers too, no matter the window dimensions. The one showing the node served version always has larger text than the static variant. Both times there's no error in the browser consoles AFAICT.

If you're interested in replicating this:

git clone --branch=reveal-md_issue https://github.com/renefritze/22-esco repo
cd repo
make install
make html
xdg-open docs/22-esco-slides.html &
make watch

I think I've somewhat figured this out: The cause for this is that the template is missing init/default values for controls and slideNumber and my slides.md sets them. If I now do add those (even with values that are different from what the .md sets) I get static slides that look just like the ones served from --watch.