This code fails: ``` export const PostUsersRolesDataValidator : Joi.ObjectSchema = Joi.object().keys({ roles: Joi.object().required(), franchiseeId: Joi.string().min(36).max(36).when('franchisorId', { is: false, then: Joi.required() }), franchisorId: Joi.string().min(36).max(36).when('franchiseeId', { is: false, then: Joi.required() }) }); ``` with the error `../shared/joiValidators/PostUsersRolesDataValidator.ts(5,90): error TS2339: Property 'required' does not exist on type 'typeof 'joi''.` Idea from here: https://github.com/hapijs/joi/issues/194
This code fails:
with the error
../shared/joiValidators/PostUsersRolesDataValidator.ts(5,90): error TS2339: Property 'required' does not exist on type 'typeof 'joi''.Idea from here: hapijs/joi#194