Data validation with Zod and TypeScript #3366
              
                Unanswered
              
          
                  
                    
                      Gpx
                    
                  
                
                  asked this question in
                Show and tell
              
            Replies: 1 comment 1 reply
-
| @Gpx I know it's an old thread but: I went to use your approach and it's great, thanks for sharing it :) The minor change I've made is to pass the  | 
Beta Was this translation helpful? Give feedback.
                  
                    1 reply
                  
                
            
  
    Sign up for free
    to join this conversation on GitHub.
    Already have an account?
    Sign in to comment
  
        
    
Uh oh!
There was an error while loading. Please reload this page.
-
Hi all, I started using the approach described in this article to validate my query request and response data with Zod and TypeScript. I'll post the interesting bit of code here:
I was wondering what everyone thought about it. If people find it useful, I'm thinking of publishing a library that generalizes the same approach.
Thanks for the feedback!
Beta Was this translation helpful? Give feedback.
All reactions