Skip to content

Commit 6810627

Browse files
avnashgaearon
authored andcommitted
Fix: updated with new docs links (facebook#8049)
1 parent 37f94bd commit 6810627

File tree

8 files changed

+17
-17
lines changed

8 files changed

+17
-17
lines changed

CHANGELOG.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -388,7 +388,7 @@ Each of these changes will continue to work as before with a new warning until t
388388

389389
- `React.initializeTouchEvents` is no longer necessary and has been removed completely. Touch events now work automatically.
390390
- Add-Ons: Due to the DOM node refs change mentioned above, `TestUtils.findAllInRenderedTree` and related helpers are no longer able to take a DOM component, only a custom component.
391-
- The `props` object is now frozen, so mutating props after creating a component element is no longer supported. In most cases, [`React.cloneElement`](https://facebook.github.io/react/docs/top-level-api.html#react.cloneelement) should be used instead. This change makes your components easier to reason about and enables the compiler optimizations mentioned above.
391+
- The `props` object is now frozen, so mutating props after creating a component element is no longer supported. In most cases, [`React.cloneElement`](https://facebook.github.io/react/docs/react-api.html#cloneelement) should be used instead. This change makes your components easier to reason about and enables the compiler optimizations mentioned above.
392392
- Plain objects are no longer supported as React children; arrays should be used instead. You can use the [`createFragment`](https://facebook.github.io/react/docs/create-fragment.html) helper to migrate, which now returns an array.
393393
- Add-Ons: `classSet` has been removed. Use [classnames](https://github.com/JedWatson/classnames) instead.
394394
- Web components (custom elements) now use native property names. Eg: `class` instead of `className`.
@@ -399,7 +399,7 @@ Each of these changes will continue to work as before with a new warning until t
399399
- `setProps` and `replaceProps` are now deprecated. Instead, call ReactDOM.render again at the top level with the new props.
400400
- ES6 component classes must now extend `React.Component` in order to enable stateless function components. The [ES3 module pattern](https://facebook.github.io/react/blog/2015/01/27/react-v0.13.0-beta-1.html#other-languages) will continue to work.
401401
- Reusing and mutating a `style` object between renders has been deprecated. This mirrors our change to freeze the `props` object.
402-
- Add-Ons: `cloneWithProps` is now deprecated. Use [`React.cloneElement`](https://facebook.github.io/react/docs/top-level-api.html#react.cloneelement) instead (unlike `cloneWithProps`, `cloneElement` does not merge `className` or `style` automatically; you can merge them manually if needed).
402+
- Add-Ons: `cloneWithProps` is now deprecated. Use [`React.cloneElement`](https://facebook.github.io/react/docs/react-api.html#cloneelement) instead (unlike `cloneWithProps`, `cloneElement` does not merge `className` or `style` automatically; you can merge them manually if needed).
403403
- Add-Ons: To improve reliability, `CSSTransitionGroup` will no longer listen to transition events. Instead, you should specify transition durations manually using props such as `transitionEnterTimeout={500}`.
404404

405405
### Notable enhancements

src/isomorphic/children/ReactChildren.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ function forEachSingleChild(bookKeeping, child, name) {
5555
/**
5656
* Iterates through children that are typically specified as `props.children`.
5757
*
58-
* See https://facebook.github.io/react/docs/top-level-api.html#react.children.foreach
58+
* See https://facebook.github.io/react/docs/react-api.html#react.children.foreach
5959
*
6060
* The provided forEachFunc(child, index) will be called for each
6161
* leaf child.
@@ -148,7 +148,7 @@ function mapIntoWithKeyPrefixInternal(children, array, prefix, func, context) {
148148
/**
149149
* Maps children that are typically specified as `props.children`.
150150
*
151-
* See https://facebook.github.io/react/docs/top-level-api.html#react.children.map
151+
* See https://facebook.github.io/react/docs/react-api.html#react.children.map
152152
*
153153
* The provided mapFunction(child, key, index) will be called for each
154154
* leaf child.
@@ -177,7 +177,7 @@ function forEachSingleChildDummy(traverseContext, child, name) {
177177
* Count the number of children that are typically specified as
178178
* `props.children`.
179179
*
180-
* See https://facebook.github.io/react/docs/top-level-api.html#react.children.count
180+
* See https://facebook.github.io/react/docs/react-api.html#react.children.count
181181
*
182182
* @param {?*} children Children tree container.
183183
* @return {number} The number of children.
@@ -191,7 +191,7 @@ function countChildren(children, context) {
191191
* Flatten a children object (typically specified as `props.children`) and
192192
* return an array with appropriately re-keyed children.
193193
*
194-
* See https://facebook.github.io/react/docs/top-level-api.html#react.children.toarray
194+
* See https://facebook.github.io/react/docs/react-api.html#react.children.toarray
195195
*/
196196
function toArray(children) {
197197
var result = [];

src/isomorphic/children/onlyChild.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ var invariant = require('invariant');
1818
* Returns the first child in a collection of children and verifies that there
1919
* is only one child in the collection.
2020
*
21-
* See https://facebook.github.io/react/docs/top-level-api.html#react.children.only
21+
* See https://facebook.github.io/react/docs/react-api.html#react.children.only
2222
*
2323
* The current implementation of this function assumes that a single child gets
2424
* passed without a wrapper, but the purpose of this helper function is to

src/isomorphic/classic/class/ReactClass.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -761,7 +761,7 @@ var ReactClass = {
761761

762762
/**
763763
* Creates a composite component class given a class specification.
764-
* See https://facebook.github.io/react/docs/top-level-api.html#react.createclass
764+
* See https://facebook.github.io/react/docs/react-api.html#createclass
765765
*
766766
* @param {object} spec Class specification (which must define `render`).
767767
* @return {function} Component constructor function.

src/isomorphic/classic/element/ReactElement.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -178,7 +178,7 @@ var ReactElement = function(type, key, ref, self, source, owner, props) {
178178

179179
/**
180180
* Create and return a new ReactElement of the given type.
181-
* See https://facebook.github.io/react/docs/top-level-api.html#react.createelement
181+
* See https://facebook.github.io/react/docs/react-api.html#createelement
182182
*/
183183
ReactElement.createElement = function(type, config, children) {
184184
var propName;
@@ -266,7 +266,7 @@ ReactElement.createElement = function(type, config, children) {
266266

267267
/**
268268
* Return a function that produces ReactElements of a given type.
269-
* See https://facebook.github.io/react/docs/top-level-api.html#react.createfactory
269+
* See https://facebook.github.io/react/docs/react-api.html#createfactory
270270
*/
271271
ReactElement.createFactory = function(type) {
272272
var factory = ReactElement.createElement.bind(null, type);
@@ -295,7 +295,7 @@ ReactElement.cloneAndReplaceKey = function(oldElement, newKey) {
295295

296296
/**
297297
* Clone and return a new ReactElement using element as the starting point.
298-
* See https://facebook.github.io/react/docs/top-level-api.html#react.cloneelement
298+
* See https://facebook.github.io/react/docs/react-api.html#cloneelement
299299
*/
300300
ReactElement.cloneElement = function(element, config, children) {
301301
var propName;
@@ -370,7 +370,7 @@ ReactElement.cloneElement = function(element, config, children) {
370370

371371
/**
372372
* Verifies the object is a ReactElement.
373-
* See https://facebook.github.io/react/docs/top-level-api.html#react.isvalidelement
373+
* See https://facebook.github.io/react/docs/react-api.html#isvalidelement
374374
* @param {?object} object
375375
* @return {boolean} True if `object` is a valid component.
376376
* @final

src/renderers/dom/client/ReactMount.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -540,7 +540,7 @@ var ReactMount = {
540540

541541
/**
542542
* Renders a React component into the DOM in the supplied `container`.
543-
* See https://facebook.github.io/react/docs/top-level-api.html#reactdom.render
543+
* See https://facebook.github.io/react/docs/react-dom.html#render
544544
*
545545
* If the React component was previously rendered into `container`, this will
546546
* perform an update on it and only mutate the DOM as necessary to reflect the
@@ -557,7 +557,7 @@ var ReactMount = {
557557

558558
/**
559559
* Unmounts and destroys the React component rendered in the `container`.
560-
* See https://facebook.github.io/react/docs/top-level-api.html#reactdom.unmountcomponentatnode
560+
* See https://facebook.github.io/react/docs/react-dom.html#unmountcomponentatnode
561561
*
562562
* @param {DOMElement} container DOM element containing a React component.
563563
* @return {boolean} True if a component was found in and unmounted from

src/renderers/dom/client/findDOMNode.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ var warning = require('warning');
2222
/**
2323
* Returns the DOM node rendered by this element.
2424
*
25-
* See https://facebook.github.io/react/docs/top-level-api.html#reactdom.finddomnode
25+
* See https://facebook.github.io/react/docs/react-dom.html#finddomnode
2626
*
2727
* @param {ReactComponent|DOMElement} componentOrElement
2828
* @return {?DOMElement} The root node of this element.

src/renderers/dom/server/ReactServerRendering.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ function renderToStringImpl(element, makeStaticMarkup) {
7777
/**
7878
* Render a ReactElement to its initial HTML. This should only be used on the
7979
* server.
80-
* See https://facebook.github.io/react/docs/top-level-api.html#reactdomserver.rendertostring
80+
* See https://facebook.github.io/react/docs/react-dom-server.html#rendertostring
8181
*/
8282
function renderToString(element) {
8383
invariant(
@@ -90,7 +90,7 @@ function renderToString(element) {
9090
/**
9191
* Similar to renderToString, except this doesn't create extra DOM attributes
9292
* such as data-react-id that React uses internally.
93-
* See https://facebook.github.io/react/docs/top-level-api.html#reactdomserver.rendertostaticmarkup
93+
* See https://facebook.github.io/react/docs/react-dom-server.html#rendertostaticmarkup
9494
*/
9595
function renderToStaticMarkup(element) {
9696
invariant(

0 commit comments

Comments
 (0)