title: Display the JSON data in parent-child hierarchical structure
body: <p>We want to display the JSON data in parent-child hierarchical structure</p>
  
  <pre><code>var JsonArr = [{
                     "comment":"Comment 1", 
                     "commentID":1, 
                     "parentID":0,
                     "children":[{
                                "comment":"Comment 1-2", 
                                "commentID":2, 
                                "parentID":1, 
                                "children":[{
                                           "comment":"Comment 1-2-2",
                                           "commentID":1,
                                           "parentID":2 
                                           }]
                              }]
                  },
                  {
                  "comment":"Comment 2", 
                  "commentID":4, 
                  "parentID":0
                 }]
  </code></pre>
  
  <p><strong>Current Output :</strong><br>
  <a href="https://i.stack.imgur.com/HEC6o.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/HEC6o.png" alt="enter image description here"></a></p>
  
  <p><strong>Expected Output :</strong><br>
  <a href="https://i.stack.imgur.com/V4ziY.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/V4ziY.png" alt="enter image description here"></a></p>
  
  <p>Working JSFiddle :
  <a href="https://jsfiddle.net/6dcdbks4/" rel="nofollow noreferrer">https://jsfiddle.net/6dcdbks4/</a></p>
  
  <p>Any Immediate help will be highly appreciable. Thanks.</p>