-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathreadme.hbs
48 lines (33 loc) · 883 Bytes
/
readme.hbs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
# Che Pollo!
ChePollo is an ultra-simple framework for common javascript client tasks, such as:
- Manipulating the DOM
- Debouncing functions
- Saving data on localStorage (falling back to cookies)
ChePollo is:
- super-light (<4kb)
- written in pure Vanilla javascript using ES6 syntax.
- transpiled to ES5 using babel and gulp
- packed in a CommonJS module or available in global scope (window.oo)
- compatible with IE > 7 (it has polyfill included)
---
## Install
```
$ npm install chepollo
```
## Usage
```js
oo.ready(function(){
var foo = oo.getById('foo');
oo.addClass(foo, 'pollastro');
oo.addData(foo, 'somekey', 'somedata');
oo.getData(foo, 'somekey'); // "somedata"
oo.debounce(function(){
foo.removeClass(foo, 'pollastro');
}, 1000)();
});
```
## API reference
{{#module name="chepollo"~}}
{{>body~}}
{{>members~}}
{{/module}}