What is the purpose of using super constructor with props argument?

What is the purpose of using a super constructor with props argument?

every class based component in react is an instance of React.Component

this means if you want to access ypur props in your instance’s constructor you need to pass you props to React.Component first and we pass it by calling super(props) inside constructor…

this wont effect any use of props outside constructor your props will always be available outside constructor.

but to use it inside constructor you need to pass it to parent class.