Lightweight and powerful data binding + templating solution for building modern web applications.

The espiritual sucessor of Rivets.js rewritten in TypeScript.

$ npm install -g @ribajs/cli
$ riba new project

Why Riba.js?

Flexible

Riba.js is completely agnostic about your model / controller layer and works well with existing libraries that employ an event-driven model such as Backbone.js and Stapes.js. It also ships with built-in support for plain JavaScript objects, so you can use Riba.js right away without needing a separate model or observables library.

Configurable

From the event handlers to the template delimiters, the attribute prefixes to the preloading of data. It's all configurable and tunable at the application level as well as locally to individual views.

Highlights

Binders

<input rv-value="item.summary">

Describe how your underlying data is reflected in the DOM and vice-versa. All binders create a binding that is automatically updated when model data changes or when the user interacts with the DOM.

Formatters

<span>{ item.due | fromNow | duration }</span>

Format dates, numbers, currencies and implement logic gates and conversions. Formatters work in a similar fashion to the Unix pipeline, so you can stack as many of them together as you like.

Adapters

<select rv-value="user.address:city">

Riba.js includes a built-in . adapter for plain JavaScript objects. Custom adapters are supported for advanced integrations with external state models. Most apps only need the default adapter.

Web Components

<toggle-item on="item.complete"></toggle-item>

Define reusable views, instantiable as a custom element. Each web component gets its own isolated, augmentable scope and are based on the custom elements browser standard.

Example

Authors

Pascal Garber byArt+Code Studio
Luiz Américo Pereira Câmara, author oftinybind
Michael Richards, original author ofRivets.js

Riba.js © 2026 ·GitHub · Version 2.0.0-rc.23