how to get type of validated request? #4251
Answered
by
RomainLanz
tsulatsitamim
asked this question in
Help
-
i want to pass validated request to x function as parameter. what is the proper type of the x function parameter? |
Beta Was this translation helpful? Give feedback.
Answered by
RomainLanz
Sep 23, 2023
Replies: 1 comment
-
Hey @tsulatsitamim! 👋🏻 You can extract the type by using the following: export type PostData = PostValidator['schema']['props']
export default class PostValidator {
constructor (protected ctx: HttpContextContract) {}
public schema = schema.create({
})
public messages = {}
} |
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
tsulatsitamim
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hey @tsulatsitamim! 👋🏻
You can extract the type by using the following: