React Rx TodoMVC 示例

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

Github星跟蹤圖

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) --+

主要指標

概覽
名稱與所有者fdecampredon/react-rxjs-todomvc
主編程語言JavaScript
編程語言HTML (語言數: 3)
平台
許可證
所有者活动
創建於2014-04-08 08:46:08
推送於2017-04-18 06:01:17
最后一次提交
發布數0
用户参与
星數341
關注者數12
派生數39
提交數22
已啟用問題?
問題數3
打開的問題數2
拉請求數4
打開的拉請求數0
關閉的拉請求數0
项目设置
已啟用Wiki?
已存檔?
是復刻?
已鎖定?
是鏡像?
是私有?