Go | 6 Unique Techniques
ฝัง
- เผยแพร่เมื่อ 2 ส.ค. 2024
- Hey everyone, welcome back! Today, we're diving into 6 unique Go techniques that will elevate your coding skills. These techniques are essential tools that can help you write more efficient, idiomatic, and maintainable Go code. Let's get started!
Timeline:
0:00 - Introduction
0:7 - Generate
1:46 - Build Tags
3:05 - Functional Options
6:09 - Context for cancellation
7:14 - Struct tags
8:44 - Conclusion
Links:
medium: / dadcod
website: dadcod.es/
Support Me on Ko-fi: ko-fi.com/dadcod
Follow Me on Twitter: / _dadcod_
Subscribe for more content: / @dadcodes
Thank you for watching! Don't forget to like, subscribe, and hit the notification bell to stay updated with more programming content. - วิทยาศาสตร์และเทคโนโลยี
Oh these are great. Especially the functional options and generators.
I understand they do not serve exactly the same purpose, but I wanted to compare them to builders since functional options are much simpler. For someone coming from a heavy OOP Java corporate background, builders might seem like the go-to solution in similar cases, but they shouldn't be.
you can use build tags to separate unit and integration tests btw.
These are great!!! Awesome video, man!! Keep doing these videos.
I'm so happy you liked it! Thanks for the support :)
Very useful tips, thanks a lot
Glad you liked it! If you have any suggestions, please share them:)
what's unique about generating code? Almost every language I know doing it
I think it would be even better to show how fast code generation is. For example some JSON parsers use reflection and some code generation.
nothing unique per se, but I like that it's built-in, simple and fast.
@@volodymyrvolodymyr3965 Reflection is runtime vs compile time for code generation, but it seems like an idea for a separate video :)