API

Decorators

@Component

@OnInit

@Evt

@El

$data

Instance Properties / Composition

mixins

Instance Methods / Events

Instance events are handled by EventEmitter custom event implementation not using DOM events. EventEmitter class is available to be imported and used in other modules.

$emit

$on

$off

Instance Methods / Lifecycle Hooks

All lifecycle hooks have their this context bound to the instance. All of them have Instance Properties available.

$teardown

beforeInit

init

beforeDestroy

destroy

DOM API

Note: Element is internal class for handling DOM manipulation that simulates jQuery but is 800% lighter, below is a reference of available methods. Other methods need to be accessed through DOM API. this.$element and all elements found using @El decorator are Element instances.

Element

Traversing

find

children

closest

parent

eq

first

get

array

Filtering

filter

map

each

is

Manipulation

clone

append

prepend

Insert content, specified by the argument, to the beginning of each element in the set of matched elements. Additional data can be provided, which will be used for populating the html

remove

text

html

attr

prop

data

addClass

removeClass

toggleClass

Events

trigger

on

off