From cc35432e9b9b3e493d5ffdb6eac1b51ed93ec5cd Mon Sep 17 00:00:00 2001 From: Samer Buna Date: Tue, 8 Nov 2016 13:15:01 -0800 Subject: [PATCH] Remove unnecessary findDOMNode calls (#8198) --- _js/live_editor.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/_js/live_editor.js b/_js/live_editor.js index 134cae5b..1dff81a5 100644 --- a/_js/live_editor.js +++ b/_js/live_editor.js @@ -21,7 +21,7 @@ var CodeMirrorEditor = React.createClass({ componentDidMount: function() { if (IS_MOBILE) return; - this.editor = CodeMirror.fromTextArea(ReactDOM.findDOMNode(this.refs.editor), { + this.editor = CodeMirror.fromTextArea(this.refs.editor, { mode: 'jsx', lineNumbers: this.props.lineNumbers, lineWrapping: true, @@ -200,7 +200,7 @@ var ReactPlayground = React.createClass({ }, executeCode: function() { - var mountNode = ReactDOM.findDOMNode(this.refs.mount); + var mountNode = this.refs.mount; try { ReactDOM.unmountComponentAtNode(mountNode);