| 18048 | } |
| 18049 | |
| 18050 | function defineKeyPropWarningGetter(props, displayName) { |
| 18051 | var warnAboutAccessingKey = function () { |
| 18052 | if (!specialPropKeyWarningShown) { |
| 18053 | specialPropKeyWarningShown = true; |
| 18054 | warning(false, '%s: `key` 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); |
| 18055 | } |
| 18056 | }; |
| 18057 | warnAboutAccessingKey.isReactWarning = true; |
| 18058 | Object.defineProperty(props, 'key', { |
| 18059 | get: warnAboutAccessingKey, |
| 18060 | configurable: true |
| 18061 | }); |
| 18062 | } |
| 18063 | |
| 18064 | function defineRefPropWarningGetter(props, displayName) { |
| 18065 | var warnAboutAccessingRef = function () { |