mirror of
https://github.com/webslides/WebSlides.git
synced 2025-09-01 17:12:43 +02:00
Updated Core API (markdown)
21
Core-API.md
21
Core-API.md
@@ -82,8 +82,7 @@ Goes to the previous slide. If the page is vertical, it will animate the scroll
|
||||
<a name="registerPlugin"></a>
|
||||
|
||||
### `registerPlugin(key, cto)`
|
||||
Registers a plugin to be loaded when the instance is created. It allows
|
||||
(on purpose) to replace default plugins.
|
||||
Registers a plugin to be loaded when the instance is created. It allows (on purpose) to replace default plugins.
|
||||
|
||||
Those being:
|
||||
|
||||
@@ -101,4 +100,20 @@ Those being:
|
||||
| Param | Type | Description |
|
||||
| --- | --- | --- |
|
||||
| key | <code>string</code> | They key under which it'll be stored inside of the instance, inside the plugins dict. |
|
||||
| cto | <code>function</code> | Plugin constructor. |
|
||||
| cto | <code>function</code> | Plugin constructor. |
|
||||
|
||||
You can [read more](Plugin-development) about plugin development.
|
||||
|
||||
### Public properties
|
||||
|
||||
These properties are inside of the WebSlides instance and they could be useful to achieve new behaviours.
|
||||
|
||||
- `el`: The DOM node to which WebSlides is attached.
|
||||
- `isMoving`: A Boolean indicating whether a transition is happening.
|
||||
- `slides`: An array of `Slide` instances. A new `Slide` instance is created for every `section` inside of `el`.
|
||||
- `isVertical`: A Boolean indicating whether WebSlides is in vertical mode.
|
||||
- `plugins`: Plugins dict which allows you to manually control some of them.
|
||||
- `options`: An object with all the options given to the constructor (as seen above).
|
||||
- `initialised`: A Boolean indicating whether WebSlides has finished the initialisation or not.
|
||||
|
||||
## `Slide` class
|
Reference in New Issue
Block a user