new Component()
Component is the base class for the React components defined as JavaScript classes. Class components are still supported by React, but we don’t recommend using them in new code.
React lets you define components as classes or functions. Components defined as classes currently provide more features which are described in detail on this page. To define a React component class, you need to extend React.Component.The only method you must define in a React.Component subclass is called render(). All the other methods described on this page are optional.
- Source:
- See: