https://github.com/lifefloating/nestjs-project-template
NestJS project template, Boilerplate. Auth, Better-Auth, Prisma, MongoDB, Pino, Docker.
https://github.com/lifefloating/nestjs-project-template
better-auth boilerplate nest nestjs node nodejs prisma template typescript
Last synced: about 1 year ago
JSON representation
NestJS project template, Boilerplate. Auth, Better-Auth, Prisma, MongoDB, Pino, Docker.
- Host: GitHub
- URL: https://github.com/lifefloating/nestjs-project-template
- Owner: lifefloating
- License: mit
- Created: 2024-12-24T01:21:02.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2025-04-03T10:22:52.000Z (about 1 year ago)
- Last Synced: 2025-04-03T10:37:37.491Z (about 1 year ago)
- Topics: better-auth, boilerplate, nest, nestjs, node, nodejs, prisma, template, typescript
- Language: TypeScript
- Homepage: https://lifefloating.github.io/nestjs-project-template/
- Size: 490 KB
- Stars: 89
- Watchers: 7
- Forks: 17
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Nest JS Project Template
A modern NestJS project structure with best practices using Fastify, Prisma, MongoDB, and SWC. and more
## Documentation
- [Installation and Running Guide](./docs/install&run.md)
- [Cloud Storage Integration Guide (Chinese)](./docs/storage-guide.md) | [English](./docs/storage-guide-en.md)
- [OAuth Authentication Guide (Chinese)](./docs/oauth-guide.md) | [English](./docs/oauth-guide-en.md)
## commit Doc
- [Commit Convention](./COMMIT_CONVENTION.md)
## 📋 Tech Stack
- **Framework**: [NestJS 10.x](https://nestjs.com/) with [Fastify](https://www.fastify.io/)
- **Database**: [MongoDB](https://www.mongodb.com/) with [Prisma ORM](https://www.prisma.io/)
- **Compiler**: [SWC](https://swc.rs/) for TypeScript
- **Package Manager**: [pnpm](https://pnpm.io/)
- **Authentication**: JWT with [Passport](https://www.passportjs.org/)
- **Documentation**: [Swagger/OpenAPI](https://swagger.io/)
- **Validation**: [class-validator](https://github.com/typestack/class-validator) with DTOs
- **Logging**: [Pino](https://getpino.io/) for structured logging
- **Testing**: [Jest](https://jestjs.io/)
- **Linting**: [ESLint](https://eslint.org/) with TypeScript rules (inspired by [brocoders/nestjs-boilerplate](https://github.com/brocoders/nestjs-boilerplate))
- **Storage**: Multi-cloud storage support ([Alibaba Cloud OSS](https://www.alibabacloud.com/product/object-storage-service), [Tencent Cloud COS](https://www.tencentcloud.com/products/cos), [Amazon S3](https://aws.amazon.com/s3/))
## Features
- Modular architecture with proper separation of concerns
- Global exception handling and request/response transformation
- Database integration with Prisma ORM
- Structured logging
- API documentation with Swagger
- Configuration management with validation
- Authentication and authorization with multiple OAuth providers (Google, GitHub, Facebook, Twitter, Microsoft, Discord, Apple)
- Unit and e2e testing setup
- Performance optimized with Fastify and SWC
- Git hooks with Husky and [conventional commits](./COMMIT_CONVENTION.md)
- Unified cloud storage interface with multiple provider support
## Getting Started
For installation and running instructions, please see the [Installation and Running Guide](./docs/install&run.md).
## develop plan
- [plan](https://github.com/lifefloating/nestjs-project-template/discussions/11)
## License
[MIT](LICENSE)