comparar
Ajv vs class-validator
Os mesmos fatos para os dois, lidos do GitHub toda noite, e a relação que uma pessoa revisou.
| Fato | Ajv | class-validator |
|---|---|---|
| Linguagem | TypeScript | TypeScript |
| Licença | MIT | MIT |
| Estrelas | 15k | 12k |
| Última release | v8.20.0 | v0.15.1 |
| Último push | 2026-09-06 | 2026-03-25 |
| Ritmo de releases | cerca de 35 dias entre releases | cerca de 47 dias entre releases |
| Contribuidores ativos | 0 autor de commits na branch padrão nos últimos 90 dias | 0 autor de commits na branch padrão nos últimos 90 dias |
| Alertas | nenhum | nenhum |
Como se relacionam
Os dois substituem Joi. Alternativas a Joi →
ParcialAjvValidates against JSON Schema documents instead of a builder API.
Parcialclass-validatorValidation rules declared as decorators on TypeScript classes instead of a schema object.
Ajv
- v8.20.02026-04-24fix: add support for node 22/24, drop node 16/21
- v8.19.02026-04-24fix prototype pollution via format keyword using $data ref
- v8.18.02026-02-14feat: allow tree-shaking by adding "sideEffects": false to package.json
- v8.17.12024-07-12bump version to 8.17.1
- v8.17.02024-07-10The only functional change is to switch from uri-js (which is no longer supported), to fast-uri. This is the second att…
class-validator
- v0.15.12026-02-26chore: publish 0.15.0 for real
- v0.15.02026-02-26feat: add IsISO31661Numeric decorator for country codes
- v0.14.42026-02-25build(deps-dev): bump js-yaml from 3.14.1 to 3.14.2 by @dependabot[bot] in
- v0.14.32025-11-24build: update validator to 13.15.20
- v0.14.22025-05-02fix: forbidUnknownValues should default true when validatorOptions undefined
Ajv
✓ assinada A última release, v8.20.0, tem uma assinatura verificada pelo GitHub.
Carregando o relatório de segurança
class-validator
✓ assinada A última release, v0.15.1, tem uma assinatura verificada pelo GitHub.
Carregando o relatório de segurança