I've got a structure that looks like this:
items: [
{
title: 'Parent',
content: {
title: 'Child1',
content: [
{
title: 'Child2',
content: {
newFea: 'Child3'
},
},
{
title: 'Child2',
content: {
newFea: 'Child3'
},
},
{
title: 'Child2',
},
{
title: 'Child2',
content: {
newFea: 'Child3'
},
},
{
title: 'Child2',
}
]
},
},
],
On the front end, each Child2 has its own button. When the button is clicked, I wish to include Child3 in their content using { newFea: '' }.
Any suggestions on how I can accomplish this?