To display the JSON below as an image, click https://i.stack.imgur.com/tixu4.png
let finalSplit = [
{
start: "73",
end: "76",
splits: [
{
word: "Now",
start: "73",
color:"#FF6262",
name:"extra",
end: "76",
},
],
},
{
start: "27",
end: "72",
splits: [
{
word: "GitHub Actions",
start: "31",
name:"sub1",
color:"#DFF652",
end: "45",
},
{
word: "the GitHub Actions “New Workflow” experience.",
start: "27",
name:"main",
color:"#62FF8E",
end: "72",
},
{
word: "GitHub",
start: "31",
name:"sub2",
color:"#9483FF",
end: "37",
},
],
},
];
I attempted to render each array in a loop but encountered duplicates, preventing me from rendering it in an aggregated form.
const Mark = () => {
return (
<>
{
finalSplit.map((i)=>{
return (
<div>
i.split.map((j)=>{
<div>{j.text}</div>
})
</div>
)
})
}
<>
);
}
I need to generate another structure with text: "announcing improvements to the GitHub Actions “New Workflow” experience. Now, when you want to create" along with their respective offsets.