#' @prisma/client did not initialize yet.' with Docker
1 messages · Page 1 of 1 (latest)
when you run docker compose for the first time, and you aren't directly copying your node_modules the types that prisma uses don't exist yet
you need to create a command to run prisma generate
where should I do this?
you can either do it in the docker compose or you can do it in the with the command block
I forgot the cmd, but it's one to do multiple commands
so you can do somehting like npx prisma generate & npm run start:dev
I'm not entirely sure if you can do it in the docker file
does what I said make sense?
One sec, I'll check
https://stackoverflow.com/questions/30063907/docker-compose-how-to-execute-multiple-commands here you go for multiple commands
depending on if you're on windows or macos, you would use bash or sh respectively
I guess it works! Thank you🤍
if you're still a little confused I'd be happy to explain haha
I have another small question: when I install new npm module, types too, it says "cannot find module or its type declaration". What can be the problem?
can I get a picture of the issue? or can you just paste the error in here?
not sure if the bcrypt module comes with type definitions, but did you install those?
yes, I did
can the problem appear because of the Docker?
I believe so, I can't remember why
but I previously used to use bcrypt, but I changed to using bcryptjs instead for some reason taht I can't remember anymore
should I try?
try installing bcryptjs and @types/bcryptjs
ok. one sec
uhhh if you'd like
the methods are slightly different, but should also get the job done
one source said that as a solution. is it ok?
it could be... I've never put a volume on an API before, so I'm not entirely sure if that's the issue
can you provide a minium reproduction of this?
wdym?
like a the bare necessities to replicate the repository