2022-07-14
1744
#vue
Nyior Clement
123578
Jul 14, 2022 â‹… 6 min read

Vue recursive components: Rendering nested comments

Nyior Clement I'm an all around software engineer who codes, writes, and sometimes designs. If you want to talk Python, I'm your guy. I own this poky corner of the interwebs xD.

Recent posts:

Rxjs Adoption Guide: Overview, Examples, And Alternatives

RxJS adoption guide: Overview, examples, and alternatives

Get to know RxJS features, benefits, and more to help you understand what it is, how it works, and why you should use it.

Emmanuel Odioko
Jul 26, 2024 â‹… 13 min read
Decoupling Monoliths Into Microservices With Feature Flags

Decoupling monoliths into microservices with feature flags

Explore how to effectively break down a monolithic application into microservices using feature flags and Flagsmith.

Kayode Adeniyi
Jul 25, 2024 â‹… 10 min read
Lots of multi-colored blue and purplish rectangles.

Animating dialog and popover elements with CSS @starting-style

Native dialog and popover elements have their own well-defined roles in modern-day frontend web development. Dialog elements are known to […]

Rahul Chhodde
Jul 24, 2024 â‹… 10 min read
Using Llama Index To Add Personal Data To Large Language Models

Using LlamaIndex to add personal data to LLMs

LlamaIndex provides tools for ingesting, processing, and implementing complex query workflows that combine data access with LLM prompting.

Ukeje Goodness
Jul 23, 2024 â‹… 5 min read
View all posts

One Reply to "Vue recursive components: Rendering nested comments"

  1. @Nyior Clement, great article: Vue recursive components: Rendering nested comments
    I have a question in regard of that. In my case, I am creating a component to render categories and subcategories. The recursive component fits very well, so, in our case, we can have multiple levels but do not want to render them in a tree-like structure. The goal is, that when the user clicks the top-level category, second-level category children will be open, and when the user clicks one of the second-level category items (row), the third row with a third-level category children will show up, and so on. Do you have a better approach to solving this challenge using native VueJs? maybe using render function inside the component? I am using vuejs 2.7 and found portal-vue to render the items in a different DOM outside the component, but it isn’t good enough. Maybe teleport for vuejs3 could work.
    Thanks in advance,
    Joel

Leave a Reply