statics 对象容许你定义静态的方法,这些静态的方法能够在组件类上调用。例如spa
statics
var MyComponent = React.createClass({ statics: { customMethod: function(foo) { return foo === 'bar'; } }, render: function() { } }); MyComponent.customMethod('bar'); // true