some very basic documentation of the API

This commit is contained in:
Bartek Szopka
2012-02-15 21:10:56 +01:00
parent f248a39aab
commit ff81a13054

View File

@@ -293,6 +293,28 @@
<script src="js/impress.js"></script>
<script>impress();</script>
<!--
The `impress()` function also gives you access to API to control the presentation.
Just store the result of the call:
var api = impress();
and you will get three functions you can call:
`api.next()` - moves to next step of the presentation,
`api.prev()` - moves to previous step of the presentation
`api.goto( stepElement ) - moves the presentation to given step element (the DOM element of the step).
You can also simply call `impress()` again to get the API, so `impress().next()` is also allowed.
Don't worry, it wont initialize the presentation again.
For some example uses of this API check the last part of the source of impress.js where the API
is used in event handlers.
-->
</body>
</html>