0 votes
in ReactJS by
What is render() in React? And explain its purpose?

1 Answer

0 votes
by

Each React component must have a render() mandatorily. It returns a single

React element which is the representation of the native DOM component. If

more than one HTML element needs to be rendered, then they must be

grouped together inside one enclosing tag such as <form>, <group>, <div>

etc. This function must be kept pure i.e., it must return the same result each

time it is invoked.

Top 250+ Ansible Interview Question

Top 250+ Augmented Reality Interview Question

Top 250+ Virtual Reality Interview Question

Top 250+ Angular Interview Question

Related questions

0 votes
asked Apr 15, 2022 in ReactJS by Robindeniel
0 votes
asked Dec 14, 2019 in ReactJS by AdilsonLima
0 votes
asked Nov 26, 2019 in ReactJS by AdilsonLima
...