diff --git a/src/popup/components/InputArea.js b/src/popup/components/InputArea.js index 426d654..b97ab06 100644 --- a/src/popup/components/InputArea.js +++ b/src/popup/components/InputArea.js @@ -13,6 +13,14 @@ export default class InputArea extends Component { handleInputText = e => { const inputText = e.target.value; this.props.handleInputText(inputText); + }; + + shouldComponentUpdate(nextProps) { + const shouldUpdate = this.props.inputText !== nextProps.inputText; + return shouldUpdate; + } + + componentDidUpdate = () => { this.resizeTextArea(); };