Contact Form Component using React, TypeScript and TailwindCSS

Solution retrospective
Something I'm very proud of is being able to create the form logic with TypeScript
using a custom hook typing its entry values and errors.
Of course, as it is my first TypeScript
project, things aren't gonna be perfect the first time, so, feel free to share tips or suggestions to improve my code!
The fact that this is my first project with TypeScript
was indeed, the actual challenge, since I understand not everything has to be typed since TS can infer when it comes down to primitive data types. If I had to list specific challenges, I'd have to say:
- Centralizing types that might be reused in most components
- Typing complex functionality (
useForm.tsx
, for example) - Typing complex reusable components
As I mentioned, previously, neither my React, TailwindCSS or TypeScript code aren't perfect at all, so any suggestions and tips are well received.
Please log in to post a comment
Log in with GitHubCommunity feedback
No feedback yet. Be the first to give feedback on RamssC's solution.
Join our Discord community
Join thousands of Frontend Mentor community members taking the challenges, sharing resources, helping each other, and chatting about all things front-end!
Join our Discord