how to get better at typescript (feat. kysely)
HTML-код
- Опубликовано: 9 июл 2024
- While videos and blog posts are great, but nothing teaches me faster than trying to duplicate a cool pattern or technique. Sometimes that pattern comes from other languages, like Rust, and sometimes, it's something that TS developers who are way smarter than me have come up with.
Code from the video: gist.github.com/andrew8088/d1...
My Links
shaky.sh
shaky.sh/tools
/ andrew8088 - Наука
❤ from Kysely.
Awesome video and a great way to demo actual generics outside of some of the very esoteric typescript challenges!
Andrew I love your videos mate. Such a humble approach. You’d be a great tech lead / principal to work with.
one of your best, so nice to see you think.
a master at work
Here I was thinking I knew Typescript... 😅
Great video Andrew.
Awesome video! And great exercise 👨🏻💻
Thanks for this, pleas give us more advanced typescript💯
Definitely not the beginner way to learn TypeScript, but pretty cool nonetheless.
For sure! But I think a lot of us know the basics, but want to keep learning past that plateau.
Yo man, this is awesome
Great content.
Can I have those typescript challenges links that you mentioned at the end ?
Hey Andrew, thanks for another great video, I have learned so much from your channel over the past 5-6 months. I just have a quick question.
The T extends T syntax (at 06:18) always confused me a little bit. I understand what it achieves here (for example you can perform a check or a modification for each member of the union), but are there any other practical use cases where you would use T extends T (to start distribution) or is that only/mostly good when working with string literal unions (or other primitive union types).
Basically I'm just asking if it's useful for other things.
Cheers!
Thanks for watching!
It's mainly useful for distribution, but not just with primitive union types. Check out my recent video about this:
ruclips.net/video/JyUwtRuMKUk/видео.html
@@andrew-burgess I've actually watched that video, but it didn't really "click" for me yet (yes I know, not the sharpest tool in the shed haha). Now that I've seen both I get a much clearer picture, thank you very much!
One of the harder things about TypeScript at least from a personal experience is not just knowing about a certain technique but when and how to use it, and/or picking up good habits such as demonstrated in your videos. For that you need a good example and a little bit of practice.
Cheers again!
this is cool, i have always struggled with typescript generics and got lost as soon as you hit 4:23. Any tips?
Start doing the typescript challenges! By far the best way to get your hands dirty and progress quickly!
This is exactly right!
太强了!
me coming from searching kysely: wow 😅
the only take away from this is TS Generics are more powerful than my thought
i genuinely get scared when i see this kind of ts videos
Why is that?
@@andrew-burgess because it makes me question whether I really even know TS or not, because after watching your videos one thing I know for sure is I only touched the tip of the iceberg. this is a good thing btw, your doing a great job
10 years working with JS, I absolutely hate TS. Trying to learn it and it just feels gross. 3.5 minutes into this video and already no idea wtf is going on. Declare? keyof?
TS is dying
Really? What's taking its place?