astefanutti / decktape

PDF exporter for HTML presentations
MIT License
2.17k stars 175 forks source link

Unable to activate the Reveal JS DeckTape #234

Closed cenk1cenk2 closed 2 years ago

cenk1cenk2 commented 2 years ago

Hello @astefanutti ,

Thanks for your work on this beautiful plugin, that saves me a lot of time.

Recently I have wrapped the reveal.js in react. But now it fails to find the reveal.js even though I specifically run it with reveal.js mode.

{
    "export:pdf": "docker run --rm -t -v $(pwd)/exports:/slides --user 0 --network host astefanutti/decktape reveal --load-pause 5000 http://localhost:3000/?showNotes=separate-page presentations-web-development-grundlagen-introduction.pdf --size 1920x960"
}

What I can add to my configuration so that this gets working again. Any help is appreciated, even though this is a novelty case and not a bug report, I failed to find it on my own.

You can see the repository here. https://github.com/cenk1cenk2/react-presentations

cenk1cenk2 commented 2 years ago

Okay, I am so sorry. I was just missing Reveal in window object, that was why it was going crazy because it was referenced by reacts useRef hook.

astefanutti commented 2 years ago

Thanks for the feedback. I'm glad to hear it works.

sadikyalcin commented 1 year ago

How did you expose it to the window?

cenk1cenk2 commented 1 year ago

Hey @sadikyalcin

It was something to do implicitly as follows for my case at least. I suppose if you import reveal as js that would be something that it would do on its own. But after thqt decktape started pick8ng up this is a reveal presentation.

https://github.com/cenk1cenk2/react-presentations/blob/9d288b7427f133de02fc59bfe6af135f79b89fad/packages/react-reveal-base/src/components/RevealJS.tsx#L545