| 18839 | } |
| 18840 | |
| 18841 | function defineRefPropWarningGetter(props, displayName) { |
| 18842 | var warnAboutAccessingRef = function () { |
| 18843 | if (!specialPropRefWarningShown) { |
| 18844 | specialPropRefWarningShown = true; |
| 18845 | warning(false, '%s: `ref` is not a prop. Trying to access it will result ' + 'in `undefined` being returned. If you need to access the same ' + 'value within the child component, you should pass it as a different ' + 'prop. (https://fb.me/react-special-props)', displayName); |
| 18846 | } |
| 18847 | }; |
| 18848 | warnAboutAccessingRef.isReactWarning = true; |
| 18849 | Object.defineProperty(props, 'ref', { |
| 18850 | get: warnAboutAccessingRef, |
| 18851 | configurable: true |
| 18852 | }); |
| 18853 | } |
| 18854 | |
| 18855 | /** |
| 18856 | * Factory method to create a new React element. This no longer adheres to |