Tumortisch-Dist/resources/app/node_modules/joi/lib/schemas.js

26 lines
649 B
JavaScript
Raw Permalink Normal View History

2021-06-15 16:00:08 +02:00
'use strict';
// Load modules
const Joi = require('./index');
// Declare internals
const internals = {};
exports.options = Joi.object({
abortEarly: Joi.boolean(),
convert: Joi.boolean(),
allowUnknown: Joi.boolean(),
skipFunctions: Joi.boolean(),
stripUnknown: [Joi.boolean(), Joi.object({ arrays: Joi.boolean(), objects: Joi.boolean() }).or('arrays', 'objects')],
language: Joi.object(),
presence: Joi.string().only('required', 'optional', 'forbidden', 'ignore'),
raw: Joi.boolean(),
context: Joi.object(),
strip: Joi.boolean(),
noDefaults: Joi.boolean(),
escapeHtml: Joi.boolean()
}).strict();