Skip to content

Commit d5670fd

Browse files
committed
Use ref prop type
1 parent e5fde66 commit d5670fd

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

packages/enzyme-adapter-utils/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
"author": "Leland Richardson <[email protected]>",
3636
"license": "MIT",
3737
"dependencies": {
38-
"airbnb-prop-types": "^2.12.0",
38+
"airbnb-prop-types": "^2.13.2",
3939
"function.prototype.name": "^1.1.0",
4040
"object.assign": "^4.1.0",
4141
"object.fromentries": "^2.0.0",

packages/enzyme-adapter-utils/src/createMountWrapper.jsx

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
import React from 'react';
22
import PropTypes from 'prop-types';
3+
import { ref } from 'airbnb-prop-types';
34
import RootFinder from './RootFinder';
45

56
/* eslint react/forbid-prop-types: 0 */
@@ -110,7 +111,7 @@ export default function createMountWrapper(node, options = {}) {
110111
props: PropTypes.object.isRequired,
111112
wrappingComponentProps: PropTypes.object,
112113
context: PropTypes.object,
113-
forwardedRef: PropTypes.oneOfType([PropTypes.func, PropTypes.object]),
114+
forwardedRef: ref(),
114115
};
115116
WrapperComponent.defaultProps = {
116117
context: null,

0 commit comments

Comments
 (0)