join strings in array of JSON objects using .map
const ratings = [
{
'rank': '133',
'category': 'Toys & Games'
},
{
'rank': '3',
'category': 'Toys & Games > Games > Board Games'
}
];
console.log(ratings.map(rating => {
return `${rating.category} : ${rating.rank}`;
}).join('\n'));