Conversation
fox1t
left a comment
There was a problem hiding this comment.
LGTM however we should remove mongoose from the project. Usually, it becomes a major pain and bottleneck when using mongodb in production.
| "graphql-tools": "~6.2.0", | ||
| "make-promises-safe": "~5.1.0", | ||
| "mercurius": "~6.3.0", | ||
| "mongoose": "~5.10.7", |
There was a problem hiding this comment.
We are not going to use mongoose since it is really slow and it will become a major bottleneck soon. For the moment we can leave just the mongodb driver
| "@commitlint/prompt": "~11.0.0", | ||
| "@types/glob": "~7.1.1", | ||
| "@types/mkdirp": "~1.0.0", | ||
| "@types/mongoose": "~5.7.36", |
| // fastify.register(fastifyHelmet) | ||
| fastify.register(mercurius, { | ||
| defineMutation: true, | ||
| } as any) |
There was a problem hiding this comment.
Are the types wrong here? If so we can make a PR to mercurius.
| import mongoose, { Schema, Types } from 'mongoose' | ||
| import Patient from '../model/Patient' | ||
|
|
||
| const PatientSchema = new Schema({ |
There was a problem hiding this comment.
Let's use json schema for the schemas so we can add them to fastify too when needed.
| "fastify-no-icon": "~4.0.0", | ||
| "fastify-plugin": "~3.0.0", | ||
| "graphiql": "~1.0.5", | ||
| "graphql-tools": "~7.0.0" |
There was a problem hiding this comment.
Missed a comma here which is causing build failure. Thankyou
|
|
No description provided.