Skip to content

raymond-h/feathers-hooks-validate-superstruct

Repository files navigation

feathers-hooks-validate-superstruct

FeathersJS hook for validating input using superstruct

Install

npm install feathers-hooks-validate-superstruct

Usage

const validateSuperstruct = require('feathers-hooks-validate-superstruct');

const app = ...; // feathers app object
const Struct = ...; // superstruct instance

app.service('service-name').hooks({
  before: {
    create: validateSuperstruct(Struct)
  }
});

About

FeathersJS hook for validating input using superstruct

Resources

License

Stars

Watchers

Forks

Packages

No packages published