Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/vedant343/zod-validation
Demonstrating ZOD for validation in NextJS
https://github.com/vedant343/zod-validation
Last synced: 9 days ago
JSON representation
Demonstrating ZOD for validation in NextJS
- Host: GitHub
- URL: https://github.com/vedant343/zod-validation
- Owner: vedant343
- Created: 2024-04-13T02:50:03.000Z (9 months ago)
- Default Branch: main
- Last Pushed: 2024-07-22T10:35:58.000Z (6 months ago)
- Last Synced: 2024-11-09T00:35:03.959Z (2 months ago)
- Language: TypeScript
- Size: 158 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Zod Validation for MongoDB Project
This project utilizes Zod for data validation and interacts with a MongoDB database. Below are key components and instructions for getting started.
## Setup
- Ensure Node.js and MongoDB are installed.
- Clone the repository and install dependencies with `npm install`.## Scripts
- `npm run dev`: Start the development server.
- `npm run build`: Build the project.
- `npm start`: Start the production server.
- `npm run lint`: Run ESLint for code linting.## Schemas
- `src/schemas/signUpSchema.ts`: Defines validation schema for user sign up.
- `src/schemas/verifySchema.ts`: Defines validation schema for verification code.
- `src/schemas/messageSchema.ts`: Defines validation schema for messages.
- `src/schemas/signInSchema.ts`: Defines validation schema for user sign in.
- `src/schemas/acceptMessageSchema.ts`: Defines validation schema for accepting messages.## Models
- `src/model/User.ts`: Defines the User model schema for MongoDB.
## Pages
- `src/app/page.tsx`: Entry point for the application.
## Configuration Files
- `.eslintrc.json`: ESLint configuration.
- `tsconfig.json`: TypeScript configuration.
- `postcss.config.mjs`: PostCSS configuration.
- `tailwind.config.ts`: Tailwind CSS configuration.## Additional Information
- The project is based on Next.js.
- Deployment can be done on Vercel.
- Refer to the provided scripts and documentation for more details.For detailed deployment instructions, refer to the [Next.js deployment documentation](https://nextjs.org/docs/deployment).