( prevProps, prevState )
| 48 | } |
| 49 | |
| 50 | componentDidUpdate( prevProps, prevState ) { |
| 51 | if ( this.props.language !== prevProps.language ) { |
| 52 | this.updateLanguageSettings( this.props.language ); |
| 53 | } |
| 54 | |
| 55 | if ( this.props.highlightLines !== prevProps.highlightLines ) { |
| 56 | this.highlightLines( this.props.highlightLines, prevProps.highlightLines ); |
| 57 | } |
| 58 | |
| 59 | this.editor.codemirror.setOption( 'firstLineNumber', this.props.firstLineNumber ); |
| 60 | this.editor.codemirror.setOption( 'lineNumbers', this.props.showLineNumbers ); |
| 61 | this.editor.codemirror.setOption( 'theme', this.props.theme ); |
| 62 | } |
| 63 | |
| 64 | componentWillUnmount() { |
| 65 | this.editor.codemirror.toTextArea(); |
nothing calls this directly
no test coverage detected