Answer the question
In order to leave comments, you need to log in
How to render nested structures with unknown nesting in Vue?
Goodnight.
Task: render a category tree with a visual display of nesting, and even inside the select. Top categories should denote groups of categories. A trifling, in fact, task, but on Vue I thought.
The v-if and v-for directives are not flexible by themselves. How, for example, to take into account the infinite nesting? How to do recursion? And how, for example, to render wrappers over the options of the upper categories (in the material ui component, the group is a separate type of component, inside which child options are nested)?
- category
-- category 2
--- category 3
-- category 4
- category 5
Answer the question
In order to leave comments, you need to log in
a single-file component can use itself if it has a name.
More details here - https://vuejs.org/v2/guide/components-edge-cases.h...
Tree from docks - https://vuejs.org/v2/examples/tree-view.html
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question