Javascript – Find the parent element of an array by the id of its child
I have a JS array that looks like this: const arr = [ { i: "tooltip_119", children: [ { i: "text_345", children: [] }, { i: "wraper_375", children: [ { i: "grid_15", children: [] } ] } ] }, {…