When I open the Slide Notes browser page (pressing s) the timer doesn't start. I'm using Chromium and I'm getting this error in the console
Uncaught ReferenceError: Reveal is not defined
at getTimings (notes.html:484)
at setupTimer (notes.html:541)
at handleConnectMessage (notes.html:387)
at notes.html:354
this doesn't happen in the standard view. I'm using the latest git version with Chromium 59. I'm initializing the presentation like this:
<script src="../reveal.js/lib/js/head.min.js"></script>
<script src="../reveal.js/js/reveal.js"></script>
<script>
Reveal.initialize({
dependencies: [
// Interpret Markdown in <section> elements
{ src: '../reveal.js/plugin/markdown/marked.js', condition: function() { return !!document.querySelector( '[data-markdown]' ); } },
{ src: '../reveal.js/plugin/markdown/markdown.js', condition: function() { return !!document.querySelector( '[data-markdown]' ); } },
{ src: '../reveal.js/plugin/notes/notes.js', async: true }
],
slideNumber: false
});
</script>
I'm seeing the same issue. This bug appears to have crept in in commit 715cf0b.
Took a while but I found out how to reproduce that error. It happens when you press the 'S' to open the speaker view, and then go back to the main window and press the 'S' key again while the popup is still open in the background.
It's not happening when first opening the speaker view in any browser that I've tested.
Wasn't able to find a way to fix it yet though.
To me it does happen the first time I press s.
It happened for me the first time I pressed s as well. Using incognito mode fixed it for me, so I think it was some kind of caching issue (I had upgraded from a previous release). Killing all cache didn't seem to help, but restarting Chrome did.
I'm pulling Reveal from a CDN and have run into this issue as of 3.5.0, due to a CORS issue for the slide timing stuff.
Because notes.html is on the CDN and the main presentation is on a different domain, notes.js:25 fails, and the pop-up never gets a reference to the main window's Reveal object.
Would it be possible to use the existing message-passing postMessage() channel between the two windows to send the slide timing data, so that the Reveal object doesn't need to be shared between the two windows?
This issue doesn't appear when notes.html is on the same domain as the main presentation.
If I just git clone https://github.com/hakimel/reveal.js and then run demo.html pressing s timer just won't start and in console window what I can see is Uncaught ReferenceError: Reveal is not defined
@kuncevic, are you opening demo.html directly in the browser (file:/// URL), or running a local web server?
As per the documentation on speaker notes, notes only work from a web server.
@seanho00 i c, thanks for pointing that out. I was using a file:///
I'm having the same issue: timer not working when pressing 's', either on Chrome and Safari.
For me the following works with Firefox (for presentations served from a web server as well as with local files):
You're right, I got the same behavior on Firefox (for Mac). I could not replicate it on either Safari or Chrome, though: the timer is not working even the second time I open the window.
Update: That was when reading from a local file, when I read a presentation served from a web server the timer works OK on the three browsers, the first time I open the speaker window.
Closing since this isn't an issue as notes are meant to be run from a server for postMessage to work properly.
@bnjmnt4n
notes are meant to be run from a server
Why is that?
What's wrong in using notes (in speaker view) locally, without any server?
Previous versions used to work like that.
Please note that there are many cases in which there's no way to be online or start any server. All you can to is to show your presentation using attached USB drive.
"Be online/use server or don't use notes" is IMHO a ridiculous requirement.
EDIT: this seems to be fixed by this PR: https://github.com/hakimel/reveal.js/pull/2104 ?
Took a while but I found out how to reproduce that error. It happens when you press the 'S' to open the speaker view, and then go back to the main window and press the 'S' key again while the popup is still open in the background.
It's not happening when first opening the speaker view in any browser that I've tested.
Wasn't able to find a way to fix it yet though.
@bnjmnt4n @hakimel
This bug is still present. I can reproduce it e.g. on https://revealjs.com/ You may reconsider to open this issue again.
I am having the same issue here.
I tested revealjs.com again in Chrome canary/stable but the timer is working every time, except for the issue with pressing S while notes are already opened that I described above.
I've moved the timer bug when opening notes twice to a new issue #2229
I had the same issue, the timer didn't work for safari and chrome (whichever way I press "s").
Following the "full setup" from https://github.com/hakimel/reveal.js/ solved the issue.
Most helpful comment
@kuncevic, are you opening
demo.htmldirectly in the browser (file:///URL), or running a local web server?As per the documentation on speaker notes, notes only work from a web server.