What is the best way to get the first 3 elements looping through that React array?
const elements = [
{id:1, label:"1", value:1},
{id:2, label:"2", value:2},
{id:3, label:"3", value:3},
{id:4, label:"4", value:4},
{id:5, label:"3", value:5},
{id:6, label:"3", value:6}
];