xxxxxxxxxx
const trueCondition = true;
const falseCondition = false;
const obj = {
trueCondition && { dogs: "woof" }), (
falseCondition && { cats: "meow" }), (
};
// { dogs: 'woof' }
https://amberley.dev/blog/2020-09-07-conditionally-add-to-array-or-obj/