tRPC useQuery() or useMutation()
I have a component with a form containing a question about a secret name.
When submitting that form I want to validate that the user sent the correct secret name. What should I use? (the name will be in my environment variables)
Im currently trying to implement it with useMutation(). Is this the correct method to use?
This is what I have so far:
its currently working, but i cant f.ex do
When submitting that form I want to validate that the user sent the correct secret name. What should I use? (the name will be in my environment variables)
Im currently trying to implement it with useMutation(). Is this the correct method to use?
This is what I have so far:
its currently working, but i cant f.ex do
console.log(res.result) I then get an error Cannot read properties of undefined. This is the procedure code: 