title: How to typedef in reactJS?
body: <p>I have to use <code>this.state.&lt;name&gt;</code> multiple times, how should I replace it with a simple variable name? Like we use global variables in other languages such as C, C++. </p>