In JavaScript, I need to know if all object items are set to true.
If I have the following object:
var myObj = {title:true, name:true, email:false};
You can use every from lodash
every
const obj1 = { a: 1, b: 2, c: true }; const obj2 = { a: true, b: true, c: true }; _.every(obj1, true); // false _.every(obj2, true); // true