Why is a component constructor called only once?



Why is a component constructor called only once?..

Answer / Tripti Agarwal

A React.js component's constructor is called only once during the initial rendering of the component. This ensures that the state of the component can be initialized and any binding to event handlers can occur just once.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More React.js Interview Questions

Why do we need a router in react?

1 Answers  


When reactjs released?

1 Answers  


What is flux in react.js?

1 Answers  


Explain the term stateless components

1 Answers  


What are controlled and uncontrolled components?

1 Answers  


How to add google analytics for react router?

1 Answers  


What is the use of a super keyword in React?

1 Answers  


What is function based component?

1 Answers  


How different is react’s es6 syntax when compared to es5?

1 Answers  


What are the components in flux architecture?

1 Answers  


What are the advantages of using reactjs?

1 Answers  


How to embed two components in one component?

1 Answers  


Categories