mirror of
https://github.com/facebook/react.git
synced 2025-11-01 09:12:30 +00:00
Add links to docs for addons and top level API (#6555)
This makes it easier to figure out where the docs live. Googling for e.g. `react-addons-update` also works, but this should make things easier for people that hyperclick directly to the source.
This commit is contained in:
1 parent
256753b830
commit
db175052c0
17 files changed
+76
-7
No files matched your search
@@ -36,6 +36,8 @@ var shallowCompare = require('shallowCompare');
|
||||
* complex data structures this mixin may have false-negatives for deeper
|
||||
* differences. Only mixin to components which have simple props and state, or
|
||||
* use `forceUpdate()` when you know deep data structures have changed.
|
||||
*
|
||||
* See https://facebook.github.io/react/docs/pure-render-mixin.html
|
||||
*/
|
||||
var ReactComponentWithPureRenderMixin = {
|
||||
shouldComponentUpdate: function(nextProps, nextState) {
|
||||
|
||||
@@ -31,8 +31,11 @@ var numericPropertyRegex = /^\d+$/;
|
||||
var warnedAboutNumeric = false;
|
||||
|
||||
var ReactFragment = {
|
||||
// Wrap a keyed object in an opaque proxy that warns you if you access any
|
||||
// of its properties.
|
||||
/**
|
||||
* Wrap a keyed object in an opaque proxy that warns you if you access any
|
||||
* of its properties.
|
||||
* See https://facebook.github.io/react/docs/create-fragment.html
|
||||
*/
|
||||
create: function(object) {
|
||||
if (typeof object !== 'object' || !object || Array.isArray(object)) {
|
||||
warning(
|
||||
|
||||
@@ -16,6 +16,7 @@ var ReactStateSetters = require('ReactStateSetters');
|
||||
|
||||
/**
|
||||
* A simple mixin around ReactLink.forState().
|
||||
* See https://facebook.github.io/react/docs/two-way-binding-helpers.html
|
||||
*/
|
||||
var LinkedStateMixin = {
|
||||
/**
|
||||
|
||||
@@ -37,6 +37,9 @@
|
||||
var React = require('React');
|
||||
|
||||
/**
|
||||
* Deprecated: An an easy way to express two-way binding with React.
|
||||
* See https://facebook.github.io/react/docs/two-way-binding-helpers.html
|
||||
*
|
||||
* @param {*} value current value of the link
|
||||
* @param {function} requestChange callback to request a change
|
||||
*/
|
||||
|
||||
@@ -16,6 +16,7 @@ var shallowEqual = require('shallowEqual');
|
||||
/**
|
||||
* Does a shallow comparison for props and state.
|
||||
* See ReactComponentWithPureRenderMixin
|
||||
* See also https://facebook.github.io/react/docs/shallow-compare.html
|
||||
*/
|
||||
function shallowCompare(instance, nextProps, nextState) {
|
||||
return (
|
||||
|
||||
@@ -41,6 +41,11 @@ function createTransitionTimeoutPropValidator(transitionType) {
|
||||
};
|
||||
}
|
||||
|
||||
/**
|
||||
* An easy way to perform CSS transitions and animations when a React component
|
||||
* enters or leaves the DOM.
|
||||
* See https://facebook.github.io/react/docs/animation.html#high-level-api-reactcsstransitiongroup
|
||||
*/
|
||||
var ReactCSSTransitionGroup = React.createClass({
|
||||
displayName: 'ReactCSSTransitionGroup',
|
||||
|
||||
|
||||
@@ -16,6 +16,11 @@ var ReactTransitionChildMapping = require('ReactTransitionChildMapping');
|
||||
|
||||
var emptyFunction = require('emptyFunction');
|
||||
|
||||
/**
|
||||
* A basis for animatins. When children are declaratively added or removed,
|
||||
* special lifecycle hooks are called.
|
||||
* See https://facebook.github.io/react/docs/animation.html#low-level-api-reacttransitiongroup
|
||||
*/
|
||||
var ReactTransitionGroup = React.createClass({
|
||||
displayName: 'ReactTransitionGroup',
|
||||
|
||||
|
||||
@@ -66,6 +66,10 @@ function invariantArrayCase(value, spec, command) {
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns a updated shallow copy of an object without mutating the original.
|
||||
* See https://facebook.github.io/react/docs/update.html for details.
|
||||
*/
|
||||
function update(value, spec) {
|
||||
invariant(
|
||||
typeof spec === 'object',
|
||||
|
||||
Reference in new issue
Block a user