React Rx TodoMVC 示例

使用 React 和 RxJS 实现 TodoMVC。「TodoMVC implementation with React and RxJS」

Github stars Tracking Chart

React Rx TodoMVC Example

TodoMVC implementation built on top of React and RxJS

Running

Simply start a static server on this project folder.

Building

You have to install Browserify then simply run these command :

npm install

this will install all the dependencies and bundle the project sources files.

Implementation

This implementation has been inspired by the React Flux architecture

In this implementation has 3 main parts, a TodoStore, a list of actions contained in TodoActions, and a list of views in the form of React Components.

The TodoStore:

This store exposes 2 streams:

  • todos: An RxJS observable that will contain an up-to-date list of todos.
  • updates: an RxJS Observer that will receive operations to apply on the list of todos, those operations take the form of functions that create a new version of our todos list.

The TodoActions:

A list of Rx Observer that will be exposed to our components, this actions are registered against the updates stream of the TodoStore, and will push new operations into this stream when they receive values.

The Views:

A set of React components that will react to changes in our TodoStores todos stream.
In this implementation state and events handlers are managed in a 'reactive' way through the use of a special RxMixin.

TodoStore.todos --------------> React Components ---- (push value) ---> TodoActions-- + 
Ʌ, +--(apply operation on the todos list) ---TodoStore.updates  <--- (push operations) --+

Main metrics

Overview
Name With Ownerfdecampredon/react-rxjs-todomvc
Primary LanguageJavaScript
Program languageHTML (Language Count: 3)
Platform
License:
所有者活动
Created At2014-04-08 08:46:08
Pushed At2017-04-18 06:01:17
Last Commit At
Release Count0
用户参与
Stargazers Count341
Watchers Count12
Fork Count39
Commits Count22
Has Issues Enabled
Issues Count3
Issue Open Count2
Pull Requests Count4
Pull Requests Open Count0
Pull Requests Close Count0
项目设置
Has Wiki Enabled
Is Archived
Is Fork
Is Locked
Is Mirror
Is Private