RS
Size: a a a
RS
SC
LK
И
LK
И
DT
DT
EM
S
LK
LK
data.reduce((acc, curr, index) => {
return [...acc, {
numId: curr.numId,
levels: [
...acc[index - 1].levels,
{
ilvl: curr.ilvl,
children: [
...acc[index - 1].levels[index].children,
{
text: curr.text,
}
]
}
]
}];И
LK
MI
И
MI
DT
LK
RS