Schema based validator for AdonisJS
Please see the following the following releases to learn more about breaking changes and additions :
[!IMPORTANT] This validator is now legacy and has been ported to facilitate migration to AdonisJS 6. We now recommend migrating to VineJS and also using it for new projects.
Docs : https://v6-migration.adonisjs.com/guides/validator-introduction
validate
423a15fhttps://github.com/adonisjs/validator/compare/v13.0.2-3...v13.0.2
Full Changelog: https://github.com/adonisjs/validator/compare/v12.4.2...v13.0.2
Full Changelog: https://github.com/adonisjs/validator/compare/12.5.0...v12.6.0
Full Changelog: https://github.com/adonisjs/validator/compare/v12.4.2...12.5.0
With this release, we pull @adonisjs/validator
out of the core and do not recommend it for v6 apps. v6 apps should use VineJS.
However, existing apps migrating to v6 can install this package and continue using it.
Full Changelog: https://github.com/adonisjs/validator/compare/v13.0.2-2...v13.0.2-3
Full Changelog: https://github.com/adonisjs/validator/compare/v13.0.2-1...v13.0.2-2
Full Changelog: https://github.com/adonisjs/validator/compare/v13.0.2-0...v13.0.2-1
Full Changelog: https://github.com/adonisjs/validator/compare/v13.0.1-0...v13.0.2-0
Full Changelog: https://github.com/adonisjs/validator/compare/v13.0.0-0...v13.0.1-0
@ioc
imports in favor of standard imports. You can re-write the validator import as follows.
- import { schema, validator, rules } from '@ioc:Adonis/Core/Validator'
+ import { schema, validator, rules } from '@adonisjs/core/validator'
That's all! There are no other breaking changes
We have some plans to drastically improve the validator, but given how widespread the validator is used in every AdonisJS project, we are not planning to have any breaking changes in v6.
Post v6, we will publish an alternate package with the new API and the performance improvements. So that you can incrementally move from existing validator to the new one.
Full Changelog: https://github.com/adonisjs/validator/compare/v12.4.2...v13.0.0-0
https://github.com/adonisjs/validator/compare/v12.4.1...v12.4.2