UNPKG

768 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
8'use strict';
9
10// React 15.5 references this module, and assumes PropTypes are still callable in production.
11// Therefore we re-export development-only version with all the PropTypes checks here.
12// However if one is migrating to the `prop-types` npm library, they will go through the
13// `index.js` entry point, and it will branch depending on the environment.
14var factory = require('./factoryWithTypeCheckers');
15module.exports = function(isValidElement) {
16 // It is still allowed in 15.5.
17 var throwOnDirectAccess = false;
18 return factory(isValidElement, throwOnDirectAccess);
19};