UNPKG

710 BJavaScriptView Raw
1/**
2 * Copyright (c) 2013-present, Facebook, Inc.
3 *
4 * This source code is licensed under the MIT license found in the
5 * LICENSE file in the root directory of this source tree.
6 */
7
8if (process.env.NODE_ENV !== 'production') {
9 var ReactIs = require('react-is');
10
11 // By explicitly using `prop-types` you are opting into new development behavior.
12 // http://fb.me/prop-types-in-prod
13 var throwOnDirectAccess = true;
14 module.exports = require('./factoryWithTypeCheckers')(ReactIs.isElement, throwOnDirectAccess);
15} else {
16 // By explicitly using `prop-types` you are opting into new production behavior.
17 // http://fb.me/prop-types-in-prod
18 module.exports = require('./factoryWithThrowingShims')();
19}