how to create vuetify tree view from json data

I have data coming in this format, I have to create the vuetify treeview with this data

json: "{"DBHOSTDATA":"","DBNAMEDATA":""}"

The tree format I expect should be like this

      id: 1,
      name: "json",
      value: {
        DBHOSTDATA: "",
        DBNAMEDATA: "",
      children: [
          id: 2,
          name: "DBHOSTDATA",
          file: "txt",
          id: 3,
          name: "DBNAMEDATA",
          file: "txt",

There is a solution in this ticket that does what I want, but I don’t know how to adapt it to my data. I can have nested objects and arrays in my json.
JS / VueJs / Vuetify – Create a Tree from JSON object

Source: Vue – Stack Overflow

November 15, 2021
Category : News
Tags: treeview | Vue.js | vuejs2 | vuetify.js

Leave a Reply

Your email address will not be published. Required fields are marked *

Sitemap | Terms | Privacy | Cookies | Advertising

Senior Software Developer

Creator of @LzoMedia I am a backend software developer based in London who likes beautiful code and has an adherence to standards & love's open-source.