feathers-hook-validation-jsonschema
Validate Feathers resources using JSON Schema.
Use
Add the hook into a Feathers flow. Initialize it with either a JSON Schema object, or the URL to a schema object. AJV options may be passed as a second parameter during initialization.
'use strict' // Initialize a validator with a schema URL. const validate = // Initialize a validator with a schema URL. const validateFromUrl = // Add the validator to the Feathers service(s). // (Assumes the service has already been initialized.) app app
Development
This module currently uses the AJV validation library for the actual validation.