Skip to content

Commit

Permalink
chore(example): add adapter for fatest-validator
Browse files Browse the repository at this point in the history
  • Loading branch information
jellydn committed Mar 17, 2024
1 parent 55ae961 commit 09f2762
Show file tree
Hide file tree
Showing 3 changed files with 32 additions and 8 deletions.
3 changes: 2 additions & 1 deletion example/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
"test:e2e": "wait-on http://localhost:3000 && cypress run"
},
"dependencies": {
"@typeschema/fastest-validator": "^0.1.0",
"@typeschema/joi": "0.13.3",
"@typeschema/valibot": "0.13.4",
"@typeschema/yup": "0.13.3",
Expand All @@ -22,7 +23,7 @@
"joi": "17.12.2",
"next": "14.1.3",
"next-connect": "1.0.0",
"next-validations": "next",
"next-validations": "1.0.0-1",
"qs": "6.12.0",
"react": "18.2.0",
"react-dom": "18.2.0",
Expand Down
1 change: 1 addition & 0 deletions example/pages/api/register.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import type { NextApiRequest, NextApiResponse } from 'next';
import { withValidation } from 'next-validations';

// This is fastest-validator schema
const schema = {
name: { type: 'string', min: 3, max: 255 },
email: { type: 'email' },
Expand Down
36 changes: 29 additions & 7 deletions example/pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 09f2762

Please sign in to comment.