Flatten Children A Single Level

This expects static children as additional arguments to the constructor
and flattens any array arguments one level deep.

Component(props, child1, child2, arrayOfChildren, child3) ->
.props.children = [child1, child2, ...arrayOfChildren, child3]

This can avoid an additional heap allocation for the unflat array.

It allows you to pass nested arrays and objects like you used to. Those
aren't immediately flattened. That makes this a fairly safe change.

Passing a dynamic array without key properties will yield a warning
(once). Might consider throwing later.

Once we change the transpiler to use the new syntax, you'll end up with
a single flat array in normal usage.

This doesn't actually update the JSX transform.
style prop improvements

Some improvements to how style={{x:y}} is handled in React:
* ignores null styles, rather than setting them.

Codez:

    var highlighted = false;
    <div style={{color: highlighted ? 'red' : null}} />

Before:

    <div style="color:;"></div>

After:

    <div></div>

Respects that 0 has no units.
use key="foo" for all components

flattenChildren was only using key when child.mountInContainerNode
exists, which is defined on ReactCompositeComponent, and not
ReactNativeComponent.

This uses the isValidComponent() fn to see if we should use this key.
mapChildren

mapChilden() is similar to Array.map() and objMap() but handles deep
nested structures and follows similar rules to flattenChildren()
Add `ReactProps.func`

This adds ReactProps.func so people don't need to write the
slightly-more-cryptic ReactProps.instanceOf(Function). We should have
had this all along.
Always reassign _key for every pass

Currently we're mutating _key. Mutation here is fine, but it needs to
be idempotent - which it's not. This is causing some issues.

Instead I reassign the _key every time it passes through a flattening.
This means that it's unique and stable for a single pass through a composite
component. When it's repassed another level, it loses it previous
identity and is rekeyed by it's new location.

For auto-generated keys by index, this actually means it has the same
semantics as before flattening.

For explicit keys, it has the effect that keys need to be unique at
every level. Regardless of how the key got there. Every component needs to ensure
that it doesn't combine keys from two different sources that may collide. This
is also inline with the old semantics but less intuitive in the new model.
Revert `Object.create` in NormalizedEventListener

It seems that the use of Object.create (to comply with strict mode) in
NormalizedEventListener is not happy in IE8.
[React] Removing invariant warning about updating owner state

It seems like it's possible to render a component that ends up having an
owner. Because you can end up rendering inside a render somehow.
Support rendering different components into same node

var container = ...; // some DOM node
React.renderComponent(<div />, container);
React.renderComponent(<span />, container);

This should replace the rendered <div> with a <span>, effectively
reconciling at the root level.
Rename `domUtils` to `dom`
Add `getDefaultProps()`

As it turns out, default values are very useful. This implements
getDefaultProps(), a hook for components to provide prop values when
a prop is not specified by the user.
Re-add invariant

Bring back the invariant() that disallows setProps() and replaceProps()
on owned components.
Make ReactIdentity-test less fragile with respect to root IDs.
Only Allow `forceUpdate` on Mounted Components
Cleanup `ReactCurrentOwner` on Fatal

If a React component's render() fatals, it may contaminate
ReactCurrentOwner. This will cause the owner to be set improperly for
the next React.renderComponent() invocation (which causes an owner to be
set when there shouldn't be one).
Fix Listener Cleanup on Unmount

We need to make sure that deleteAllListeners() is invoked before we call
the superclass's unmountComponent() method or else we will lose
this._rootNodeID.

I also added an invariant and unit test to make sure we do not break
this in the future.
Move test utils internally, update for consistency
Rename `ReactEvent` to `ReactEventEmitter`

ReactEvent should be reserved for the actual object created when an
event fires. The current ReactEvent is more like EventEmitter than
anything (e.g. it sets up delegation, provides methods to attach and
remove listeners).
Add license headers to new files
React: Add @typechecks to `CallbackRegistry`