I'm trying to return a simple set in the response.
const mySet1 = new Set();
mySet1.add(1);
console.log("mySet1", mySet1);
res.status(200).json({ my_set: mySet1 });
Even though, it gets logged correctly in the console:
mySet1 Set(1) { 1 }
In POSTMAN, this is what I see:
{
"my_set": {}
}
Any idea what's going on?