the following array is generated by operation
var newarr = [{"id":"sd123","component":"start"},
{"id":"sd1a3","component":"ordinary"},
...,{"id":"sdop3","component":"end"}]
I thought it was easy to find the start group, get the target, and then loop through the source"s id, to match source"s id,push to the empty array according to the id, of source.
but in the actual coding, the ordinary for loop stops only looking for the first one. In addition, there is internal nesting and a recursion is added. As soon as it is tried, it becomes a dead loop
.