Skip to content

Commit

Permalink
Use ReactDOM for unmountComponentAtNode.
Browse files Browse the repository at this point in the history
Fixes this warning:

    React.unmountComponentAtNode is deprecated. Please use ReactDOM.unmountComponentAtNode from require('react-dom') instead.
  • Loading branch information
BradEstey committed Oct 31, 2015
1 parent a6d79a5 commit a7e2404
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/creators/OverlayViewCreator.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import {
Component,
Children,
} from "react";
import ReactDOM from "react-dom";
import {default as invariant} from "invariant";

import {default as defaultPropsCreator} from "../utils/defaultPropsCreator";
Expand Down Expand Up @@ -53,7 +54,7 @@ export default class OverlayViewCreator extends Component {
};

overlayView.onRemove = function () {
React.unmountComponentAtNode(this._containerElement);
ReactDOM.unmountComponentAtNode(this._containerElement);
this._unmountContainerFromPane();
this._containerElement = null;
};
Expand Down

0 comments on commit a7e2404

Please sign in to comment.