设为首页收藏本站

LUPA开源社区

 找回密码
 注册
文章 帖子 博客
LUPA开源社区 首页 业界资讯 软件追踪 查看内容

React v0.12发布.构建用户界面的JavaScript 库

2014-10-29 17:05| 发布者: joejoe0332| 查看: 2744| 评论: 0|原作者: oschina|来自: oschina

摘要:   React v0.12 发布,此版本引入了新术语;修改了 APIs,使得 React 一些概念更简洁。 同时还对 JSX 做了一些修改,飞起了一些函数。  此版本现已提供下载:ReactDev build with warnings:http://fb.me/react-0. ...

  React v0.12 发布,此版本引入了新术语;修改了 APIs,使得 React 一些概念更简洁。 同时还对 JSX 做了一些修改,飞起了一些函数。 


  此版本现已提供下载:

React 团队通过发布了 react  react-tools  0.12.0 包到 npm 和 react 包到 bower。

更多内容请看这里



Changelog

React Core

重大改进 

  • key and ref moved off props object, now accessible on the element directly

  • React is now BSD licensed with accompanying Patents grant

  • Default prop resolution has moved to Element creation time instead of mount time, making them effectively static

  • React.__internals is removed - it was exposed for DevTools which no longer needs access

  • Composite Component functions can no longer be called directly - they must be wrapped with React.createFactory first. This is handled for you when using JSX.

新特性

  • Spread operator ({...}) introduced to deprecate this.transferPropsTo

  • Added support for more HTML attributes: acceptCharset, classID, manifest

废弃

  • React.renderComponent --> React.render

  • React.renderComponentToString --> React.renderToString

  • React.renderComponentToStaticMarkup --> React.renderToStaticMarkup

  • React.isValidComponent --> React.isValidElement

  • React.PropTypes.component --> React.PropTypes.element

  • React.PropTypes.renderable --> React.PropTypes.node

  • DEPRECATED React.isValidClass

  • DEPRECATED instance.transferPropsTo

  • DEPRECATED Returning false from event handlers to preventDefault

  • DEPRECATED Convenience Constructor usage as function, instead wrap withReact.createFactory

  • DEPRECATED use of key={null} to assign implicit keys

Bug 修复

  • Better handling of events and updates in nested results, fixing value restoration in "layered" controlled components

  • Correctly treat event.getModifierState as case sensitive

  • Improved normalization of event.charCode

  • Better error stacks when involving autobound methods

  • Removed DevTools message when the DevTools are installed

  • Correctly detect required language features across browsers

  • Fixed support for some HTML attributes:

    • list updates correctly now

    • scrollLeft, scrollTop removed, these should not be specified as props

  • Improved error messages

React With Addons

新特性

  • React.addons.batchedUpdates added to API for hooking into update cycle

重大改进

  • React.addons.update uses assign instead of copyProperties which doeshasOwnProperty checks. Properties on prototypes will no longer be updated correctly.

Bug 修复

  • Fixed some issues with CSS Transitions

JSX

重大改进

  • Enforced convention: lower case tag names are always treated as HTML tags, upper case tag names are always treated as composite components

  • JSX no longer transforms to simple function calls

新特性

  • @jsx React.DOM no longer required

  • spread ({...}) operator introduced to allow easier use of props

Bug 修复

  • JSXTransformer: Make sourcemaps an option when using APIs directly (eg, for react-rails)

React.js 是 Facebook 推出的一个用来构建用户界面的 JavaScript 库。

Facebook开源了React,这是该公司用于构建反应式图形界面的JavaScript库,已经应用于构建Instagram网站及 Facebook部分网站。最近出现了AngularJS、MeteorJS 和Polymer中实现的Model-Driven Views等框架,React也顺应了这种趋势。React基于在数据模型之上声明式指定用户界面的理念,用户界面会自动与底层数据保持同步。与前面提及 的框架不同,出于灵活性考虑,React使用JavaScript来构建用户界面,没有选择HTML。


酷毙

雷人

鲜花

鸡蛋

漂亮
  • 快毕业了,没工作经验,
    找份工作好难啊?
    赶紧去人才芯片公司磨练吧!!

最新评论

关于LUPA|人才芯片工程|人才招聘|LUPA认证|LUPA教育|LUPA开源社区 ( 浙B2-20090187 浙公网安备 33010602006705号   

返回顶部