π Find your own Golden bug!
Vic ShΓ³stak
Posted on March 1, 2020
Introduction
Hey, people! π I came back with an interesting DX (Developer Experience) thought, that I recently realized. Let's talk about bugs on your code and why they're useful, if you want to grow up quickly.
π Table of contents
What is Golden bug? π€
Gold bug is the sum of your three states:
- You wrote code, but it doesn't work the way it should.
- You asked your friends for advice on how this code should work.
- One (or several) advice and/or code samples, gave you much more "solving the problem" and taught you something new (which you always missed or didn't know in the principle).
Exactly the same, when you show your code or dev/tech article to the Internet. Let me give you an example from my recent experience π
When I published my article about Go web app settings in YAML, one of my readers advised me to be more careful with the
func init()
, because code inside is very difficult to test.I started looking at my previous projects and found a lot of examples, where this built-in Go feature really prevented 100% coverage of my code with tests.
As a result, I have revised development model for Go web apps and got a lot of experience. There he is the Golden bug! π
βοΈ Why it will help me?
When you really don't know how to find the right solution to your problem and you get more than just a "do this" instruction, your brain remembers this solution pattern much better.
You can only gain experience, when you learn more, than you already know.
π How can I find him?
The main rule is write a lot of code every day and don't be afraid to ask more experienced friends (or people on Internet) to give you a review of your code.
Listen to people and be grateful, even when they hint that your code is terrible and will not be enough to waste time on it. Just ask to explain to you that place (fragment of your code), which you don't understand.
Experience at the top of everything!
Photo by
[Title] Limor Zellermayer https://unsplash.com/photos/k5mr8g4NBW8
[1] Rabie Madaci https://unsplash.com/photos/eo6t2CSxXhc
P.S.
If you want more articles (like this) on this blog, then post a comment below and subscribe to me. Thanks! π»
βοΈ You can support me on Boosty, both on a permanent and on a one-time basis. All proceeds from this way will go to support my OSS projects and will energize me to create new products and articles for the community.
And of course, you can help me make developers' lives even better! Just connect to one of my projects as a contributor. It's easy!
My main projects that need your help (and stars) π
- π₯ gowebly: A next-generation CLI tool that makes it easy to create amazing web applications with Go on the backend, using htmx, hyperscript or Alpine.js and the most popular CSS frameworks on the frontend.
- β¨ create-go-app: Create a new production-ready project with Go backend, frontend and deploy automation by running one CLI command.
Posted on March 1, 2020
Join Our Newsletter. No Spam, Only the good stuff.
Sign up to receive the latest update from our blog.