declare module "react-is-deprecated" { import type * as PropTypes from "prop-types"; interface PropTypesValidators { any: typeof PropTypes.any; array: typeof PropTypes.array; bool: typeof PropTypes.bool; func: typeof PropTypes.func; number: typeof PropTypes.number; object: typeof PropTypes.object; string: typeof PropTypes.string; node: typeof PropTypes.node; element: typeof PropTypes.element; instanceOf: typeof PropTypes.instanceOf; oneOf: typeof PropTypes.oneOf; oneOfType: typeof PropTypes.oneOfType; arrayOf: typeof PropTypes.arrayOf; objectOf: typeof PropTypes.objectOf; shape: typeof PropTypes.shape; exact: typeof PropTypes.exact; } export function deprecate(validator: PropTypes.Validator, message: string): PropTypes.Validator; interface Deprecatable { isDeprecated: (message: string) => PropTypes.Validator; } // Unfortunately this copy-paste must happen -- I can't just take PropTypes and programmatically // define a version that intersects in the Deprecatable interface into the keys. interface DeprecatablePropTypes { any: PropTypes.Requireable & Deprecatable; array: PropTypes.Requireable & Deprecatable; bool: PropTypes.Requireable & Deprecatable; func: PropTypes.Requireable & Deprecatable; number: PropTypes.Requireable & Deprecatable; object: PropTypes.Requireable & Deprecatable; string: PropTypes.Requireable & Deprecatable; node: PropTypes.Requireable & Deprecatable; element: PropTypes.Requireable & Deprecatable; instanceOf(expectedClass: {}): PropTypes.Requireable & Deprecatable; oneOf(types: any[]): PropTypes.Requireable & Deprecatable; oneOfType(types: Array>): PropTypes.Requireable & Deprecatable; arrayOf(type: PropTypes.Validator): PropTypes.Requireable & Deprecatable; objectOf(type: PropTypes.Validator): PropTypes.Requireable & Deprecatable; shape(type: PropTypes.ValidationMap): PropTypes.Requireable & Deprecatable; } export function addIsDeprecated(propTypes: PropTypesValidators): DeprecatablePropTypes; }