Skip to content

Instantly share code, notes, and snippets.

@oslego
Forked from cfjedimaster/gist:9903495
Created September 22, 2015 15:15
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save oslego/cfb526a57bb241e18f88 to your computer and use it in GitHub Desktop.
Save oslego/cfb526a57bb241e18f88 to your computer and use it in GitHub Desktop.
/*
I used your style, your header div, but with a slide like this
<section data-state="showHeader" data-header="custom head">
<p>Hello</p>
</section>
*/
Reveal.addEventListener( 'slidechanged', function( event ) {
// event.previousSlide, event.currentSlide, event.indexh, event.indexv
if(event.currentSlide.dataset.header) {
myHead.innerHTML = event.currentSlide.dataset.header;
}
} );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment