Skip to content

Documentation

Artem edited this page May 28, 2015 · 4 revisions

Background

propjet.js provides fluent interface for declaring reactive properties.

Conventions

Functions

propjet<T>()
propjet<T>(object, propertyName)

Starts a property declaration.


from<TPromise>()

Specifies that property is deferred.


require(...() => any)

Specifies data sources.


default(() => T)

Specifies a default value. Called when no value is set yet or some requirement is changed. It not used for regular properties with getter.


get((...sourceValues) => T)
get((...sourceValues) => TPromise)

Specifies a getter.


with((newValue, oldValue) => T)

Specifies a filter. Called after getter and before setter.


set(newValue => void)
set((newValue, ...sourceValues) => TPromise)

Specifies a setter.


declare(isFunction)

Declares a property or creates a getter/setter function.


Clone this wiki locally