Reddit-Comments-UI I have used the function(renderComments) to render through array of comments and prints comments. Using recursion to print the subcomments. I am passing some variables to the same function to determine the indetation of each comment components.