import type { ErrorObject } from 'ajv'; type Props = { errors: ErrorObject, unknown>[]; }; export function SchemaValidator({ errors }: Readonly) { if (!errors) { return null; } return (

{errors.length} erreurs

    {errors.map((err) => (
  • {err.instancePath} : {err.message}{' '} ({err.schemaPath})
  • ))}
); }