From 2caac75c62861ce2c68d2c0f2341836b2ff1aef9 Mon Sep 17 00:00:00 2001 From: andy matthews Date: Mon, 30 Apr 2012 09:07:23 -0500 Subject: [PATCH] Adding example for custom event binding. --- index.html | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/index.html b/index.html index 5346e34..0e30911 100644 --- a/index.html +++ b/index.html @@ -143,6 +143,18 @@ +
+

Custom Events

+

+ Additionally custom events can be triggered on a per slide basis by binding to the data-state name. +

+

+ document.addEventListener('customevent', function(){
+ alert('event has fired');
+ }); +

+
+

Clever Quotes

@@ -250,6 +262,10 @@ query[ a.split( '=' ).shift() ] = a.split( '=' ).pop(); } ); + document.addEventListener('customevent', function(){ + alert('event has fired'); + }); + Reveal.initialize({ // Display controls in the bottom right corner controls: true,