红联Linux门户
Linux帮助

marty.js v0.9发布,React状态管理库

发布时间:2015-03-25 09:06:18来源:红联作者:empast
marty.js 用来为 React 应用提供状态管理的 JavaScript 库,实现了 Flux architecture. 定义了一组规则用来管理应用的状态。Flux 是 Facebook 推出的用来帮助他们自己构建客户端 web 应用。

marty.js v0.9 发布,此版本关键的改进是:Store#setState 重命名为 Store#replaceState。Store#setState 现在会和新状态合并到现有状态中,这非常接近 React API。

新特性

Isomorphism (#13)

CookieStateSource & LocationStateSource (#205)

ES6 Classes (#89)

Add dataType option to http state source (#176)

Lodash v3 instead of underscore (#170)

HttpStateSource hooks (#118)

FetchResult#toPromise (#180)

Clear fetch history in Store#clear (#149)

Batch store change events (#183)

Allow you to specify when function context (#184)

Marty.createContainer (#206)

Set request credentials to 'same-origin' (#209)

Bugs 修复

dependsOn doesn't update when dependent store updates (#113)

Don't auto set content-type if using FormData (#140)

Fetch API compatibility (#133)

更多详细新特性解说请看发行说明。

软件详情:http://martyjs.org/blog/2015/03/24/marty-v0.9.html

下载地址:https://github.com/jhollingworth/marty

来自:开源中国社区
文章评论

共有 0 条评论