A tiny foundation for building reactive views with plugins. It aims to have a similar API to Reactive, but allow composition of views, like React. The major difference for other view libraries is that there are no globals used at all. Each view has its own set of bindings and plugins. This makes composition of views really easy.
var Person = ripple('<div>{{name}}</div>')
.use(events)
.use(each)
.use(dispatch);
var person = new Person({
name: 'Tom'
});
person.appendTo(document.body);
component install ripplejs/ripple
npm install ripplejs
or download the standlone version and include it on your page.
Supports real browsers and IE9+.
It's all on Github for now. Read getting started;
- events - add event listeners to the DOM and call methods on the view
- each - Basic iteration using the
each
directive. - bind-methods - Bind all methods on the prototype to the view
- markdown - Adds a directive to render markdown using Marked.
- extend - Makes adding methods to the view prototype a little cleaner
- intervals - Easily add and remove intervals
- computed - Add computed properties.
- refs - Easily reference elements within the template
- dispatch - Dispatch custom DOM events up the tree