Nestjs Prisma Monorepo

screenshot of Nestjs Prisma Monorepo
nestjs
nextjs
prisma

Nestjs Prisma Monorepo

🐈 NestJS + Prisma + Yarn Workspaces (Monorepo) full-stack project template

Overview:

The Nest Prisma Monorepo is a template created for developers who are familiar with monorepos and want to leverage the benefits of using one. It combines Nest.js, JWT, GraphQL, REST, Swagger, and Prisma to create a comprehensive solution for building web applications. The template includes features such as full Typescript support, eslint and prettier integration, CI for GitHub Actions, and utilizes Yarn version 3.1.0. It follows the convention of a Nest.js monorepo structure with separate apps and libraries, making it easy to import and share code between different parts of your application.

Features:

  • Nest.js + JWT + GraphQL (code-first) + REST + Swagger: A comprehensive stack for building web applications.
  • Prisma + utilities: Includes Prisma for database management and provides utility functions for easier development.
  • Front-end app: Comes with a static HTML file for the front-end, which can be customized or replaced with frameworks like NextJS, NuxtJS, Angular, Svelte, etc.
  • Full Typescript support: Built-in support for the Typescript programming language.
  • Common package: A shared package that can be used across all apps in the monorepo.
  • Core package + NestJS utilities: Provides additional utilities and functionalities for Nest.js.
  • ESLint Ready: Integration with ESLint for code linting.
  • Prettier Ready: Integration with Prettier for code formatting.
  • CI for GitHub Actions: Continuous Integration setup for easy development and deployment.
  • Yarn (berry) version 3.1.0: Utilizes the Yarn package manager version 3.1.0 for dependency management.
  • Prisma import: Makes it easy to import and use Prisma modules from the template rather than the default @prisma/client.
  • .env files: Requires the creation of .env files in the apps/api and lib/prisma folders after cloning the template.

Installation:

  1. Clone the template repository.
  2. Create two .env files - one in the apps/api folder and one in the lib/prisma folder. You can use the .env.example file provided as a starting point.
  3. Replace all instances of "acmes" with your organization or project name.
  4. Install dependencies by running yarn install.
  5. Start the development server by running yarn start.

Summary:

The Nest Prisma Monorepo is a comprehensive template that combines Nest.js, JWT, GraphQL, REST, Swagger, and Prisma to offer a powerful solution for building web applications. It uses a monorepo structure with separate apps and libraries and provides features such as full Typescript support, integration with ESLint and Prettier, CI for GitHub Actions, and utilizes Yarn version 3.1.0. The template also includes a static front-end file that can be easily customized or swapped with other popular front-end frameworks. With its clear installation instructions and extensive features, the Nest Prisma Monorepo is a valuable resource for developers familiar with monorepo setups.

nestjs
Nest

A progressive Node.js framework for building efficient, scalable, and enterprise-grade server-side applications with TypeScript/JavaScript.

nextjs
Next.js

Next.js is a React-based web framework that enables server-side rendering, static site generation, and other powerful features for building modern web applications.

prisma
Prisma

Prisma is a server-side library that helps developers read and write data to the database in an intuitive, efficient and safe way.

fullstack
Fullstack Boilerplates

A fullstack boilerplate provides a starter application that includes both frontend and backend. It should include database, auth, payments, user roles and other backend services to build a fully featured saas or webapps.

template
Templates & Themes

A template or theme refers to a pre-designed layout or structure that provides a basic framework for building a specific type of application or website. It typically includes good design, placeholder content and functional features, allowing developers to customize and fill in the details according to their specific needs.

eslint
Eslint

ESLint is a linter for JavaScript that analyzes code to detect and report on potential problems and errors, as well as enforce consistent code style and best practices, helping developers to write cleaner, more maintainable code.

graphql
Graphql

A website that uses GraphQL as a query language to manage data fetching and state management. This includes features such as a strongly typed schema, client-side caching, and declarative data fetching to streamline data management and optimize website performance.

typescript
Typescript

TypeScript is a superset of JavaScript, providing optional static typing, classes, interfaces, and other features that help developers write more maintainable and scalable code. TypeScript's static typing system can catch errors at compile-time, making it easier to build and maintain large applications.