Hacker News new | ask | show | jobs
by IshKebab 1611 days ago
So is he wrong about not being able to type check that then?
1 comments

Well, yes, to my understanding. If you add lang="ts" to the script block, you can write normal TypeScript code for the component logic, and it will also check props that you are passing to child components in the template. It's like renaming the file from ".jsx" to ".tsx". It might not be perfect, but I haven't encountered any problems with it so far.