A
A
alex4answ2021-02-16 18:01:13
React
alex4answ, 2021-02-16 18:01:13

What is createElement, cloneElement for?

Good afternoon, I met questions about these methods on the toaster several times, but I sincerely don’t understand what they serve for, if cloneElementI heard something like this about:

Clone the component passed to props and pass your parameters to it


then createElementmanually, without jsx, I have never heard babel, why call it manually if babel converts jsx to createElement?

What are cloneElementand used for in practice createElement?

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question