elements: { $each: { type: { required, }, question: { required: requiredIf(prop => prop.type === 'input'), } } }