1 | "use strict";
|
2 |
|
3 | var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
4 |
|
5 | exports.__esModule = true;
|
6 | exports["default"] = safeFindDOMNode;
|
7 |
|
8 | var _reactDom = _interopRequireDefault(require("react-dom"));
|
9 |
|
10 | function safeFindDOMNode(componentOrElement) {
|
11 | if (componentOrElement && 'setState' in componentOrElement) {
|
12 | return _reactDom["default"].findDOMNode(componentOrElement);
|
13 | }
|
14 |
|
15 | return componentOrElement != null ? componentOrElement : null;
|
16 | }
|
17 |
|
18 | module.exports = exports.default; |
\ | No newline at end of file |