feat: added prisma

This commit is contained in:
Krzysztof Rudnicki 2024-05-19 15:56:18 +02:00
parent 2aa364374d
commit ca280d192b
6 changed files with 15114 additions and 8 deletions

3
monorepo/apps/backend/.gitignore vendored Normal file
View File

@ -0,0 +1,3 @@
node_modules
# Keep environment variables out of version control
.env

View File

@ -0,0 +1,14 @@
generator client {
provider = "prisma-client-js"
}
datasource db {
provider = "postgresql"
url = env("DATABASE_URL")
}
model users {
id Int @id @default(autoincrement())
name String? @db.VarChar(100)
email String? @unique @db.VarChar(100)
}

View File

@ -1,7 +1,10 @@
{
"$schema": "./node_modules/nx/schemas/nx-schema.json",
"namedInputs": {
"default": ["{projectRoot}/**/*", "sharedGlobals"],
"default": [
"{projectRoot}/**/*",
"sharedGlobals"
],
"production": [
"default",
"!{projectRoot}/.eslintrc.json",
@ -34,14 +37,28 @@
"options": {
"targetName": "test"
},
"exclude": ["apps/my-workspace-e2e/**/*", "apps/my-nest-app-e2e/**/*"]
"exclude": [
"apps/my-workspace-e2e/**/*",
"apps/my-nest-app-e2e/**/*"
]
}
],
"targetDefaults": {
"@angular-devkit/build-angular:browser": {
"cache": true,
"dependsOn": ["^build"],
"inputs": ["production", "^production"]
"dependsOn": [
"^build"
],
"inputs": [
"production",
"^production"
]
},
"build": {
"inputs": [
"production",
"^production"
]
}
},
"generators": {

View File

@ -13,10 +13,13 @@
"@angular/platform-browser": "~17.3.0",
"@angular/platform-browser-dynamic": "~17.3.0",
"@angular/router": "~17.3.0",
"@nestjs/common": "^10.0.2",
"@nestjs/core": "^10.0.2",
"@nestjs/platform-express": "^10.0.2",
"@nestjs/common": "^10.3.8",
"@nestjs/core": "^10.3.8",
"@nestjs/platform-express": "^10.3.8",
"@nrwl/workspace": "^19.0.4",
"@prisma/client": "^5.14.0",
"axios": "^1.6.0",
"prisma": "^5.14.0",
"reflect-metadata": "^0.1.13",
"rxjs": "^7.8.0",
"tslib": "^2.3.0",

15068
monorepo/pnpm-lock.yaml Normal file

File diff suppressed because it is too large Load Diff

View File

@ -1,2 +1,3 @@
#!/bin/sh
nx run-many --target=serve --projects=frontend,backend --parallel
pnpm i
nx run-many --target=serve --projects=frontend,backend --parallel