docker compose front, modulo de validacion de preguntas, crud de participante, get participantes por evento y evento por participantes
This commit is contained in:
@@ -97,3 +97,25 @@ Nest is an MIT-licensed open source project. It can grow thanks to the sponsors
|
||||
## License
|
||||
|
||||
Nest is [MIT licensed](https://github.com/nestjs/nest/blob/master/LICENSE).
|
||||
|
||||
|
||||
|
||||
# usar validadores en el front end
|
||||
|
||||
import { validarRespuesta, FabricaValidadores } from
|
||||
'./validaciones/validador';
|
||||
|
||||
// To validate a single response
|
||||
const respuesta = 'user@example.com';
|
||||
const tipoValidacion = 'correo';
|
||||
const resultado = validarRespuesta(respuesta, tipoValidacion);
|
||||
|
||||
if (resultado.valido) {
|
||||
// proceed
|
||||
} else {
|
||||
// show error message: resultado.mensaje
|
||||
}
|
||||
|
||||
// Or directly use the validators
|
||||
const validadorCorreo = new ValidadorCorreo();
|
||||
const resultadoCorreo = validadorCorreo.validar('user@example.com');
|
||||
Reference in New Issue
Block a user