S
S
Sergey Khlopov2020-02-25 17:08:08
Vue.js
Sergey Khlopov, 2020-02-25 17:08:08

Creating components in a loop, is this normal in terms of performance?

Hello, please tell me, there is such a component that builds a tree, as I understand it, for each element of the tree, a new instance of the component is created. Can you please tell me if this is a good option? It's just possible to make the component take an array of objects and build a tree inside itself, but then there is a small problem with the flags that will determine whether the node is opened / closed. Thank you in advance for your response.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Alex, 2020-02-25
@Shlop

Creating components in a loop, is this normal in terms of performance?

Fine. As with almost any operation in a cycle, proceed from the task and the size of the cycle.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question