github codecoolture/next-joi v2.0.0

latest releases: v2.2.1, v2.2.0, v2.1.1...
3 years ago

Breaking Changes

This version includes breaking changes. The default export is now a factory function that can be configured to have custom error handling for validation errors. The README.md has been updated accordingly to reflect the new behavior.

import withJoi from "next-joi";

export default withJoi({
  onValidationError: (_, res) => {
    return res.status(400).end();
  },
});

Don't miss a new next-joi release

NewReleases is sending notifications on new releases.