In AuthJS official tutorial, what is saltAndHashPassword and getUserFromDb?
Answered
West African Lion posted this in #help-forum
West African LionOP
The tutorial didn't explain what the imports are:
1. Where do I find the files?
2. Do I create the files myself?
It's unclear for a beginner.
Source: https://authjs.dev/getting-started/authentication/credentials
import { saltAndHasshPassword } from "@/utils/password"
import { getUserFromDb } from "@/utils/db"1. Where do I find the files?
2. Do I create the files myself?
It's unclear for a beginner.
Source: https://authjs.dev/getting-started/authentication/credentials
4 Replies
American black bear
it looks like you would create the files yourself
Answer
@West African Lion The tutorial didn't explain what the imports are:
`import { saltAndHasshPassword } from "@/utils/password"
import { getUserFromDb } from "@/utils/db"`
1. Where do I find the files?
2. Do I create the files myself?
It's unclear for a beginner.
Source: https://authjs.dev/getting-started/authentication/credentials
they are functions you need to implement yourself
West African LionOP
thanks! that make sense!
@American black bear it looks like you would create the files yourself
West African LionOP
i missed the comment! ty