Remove findDOMNode as per warning

This commit is contained in:
Cmdr McDonald
2017-04-23 18:50:13 +01:00
parent 7db76ecba0
commit 4dc8ab928c
6 changed files with 11 additions and 29 deletions

View File

@@ -1,7 +1,6 @@
/* eslint react/no-danger: 0 */
import PropTypes from 'prop-types';
import React from 'react';
import { findDOMNode } from 'react-dom';
import TranslatedComponent from './TranslatedComponent';
/**
@@ -21,17 +20,6 @@ export default class ModalHelp extends TranslatedComponent {
super(props);
}
/**
* Focus on textarea and select all
*/
componentDidMount() {
const e = findDOMNode(this.refs.exportField);
if (e) {
e.focus();
e.select();
}
}
/**
* Render the modal
* @return {React.Component} Modal Content