tutorialspoint com react js

Solutions on MaxInterview for tutorialspoint com react js by the best coders in the world

showing results for - "tutorialspoint com react js"
Oskar
29 Mar 2019
1import React from 'react';
2
3class App extends React.Component {
4   constructor(props) {
5      super(props);
6		
7      this.state = {
8         header: "Header from state...",
9         content: "Content from state..."
10      }
11   }
12   render() {
13      return (
14         <div>
15            <h1>{this.state.header}</h1>
16            <h2>{this.state.content}</h2>
17         </div>
18      );
19   }
20}
21export default App;