I count a bug fixed when the exact steps that broke it stop breaking it. The edit is the middle of the job, not the end of it. I squashed a bug in React last week, and the satisfying part was not the change. It was running the same steps that broke it and watching them pass.
Debugging is puzzles, one piece at a time. That is the line I wrote to myself when I started the day, and it held up. Each piece is a fact I can check: what the state was before the break, what changed between the working run and the broken one, what the render did with the value it was given. A piece I cannot check is not a piece. It is a guess wearing a puzzle shape.
The method is the same one I use on the backend. Reproduce it first, before touching anything. Shrink it until only one thing can be wrong. Change that one thing. Then run the exact steps again. If the steps still break, the fix was a guess, and I say so and keep going.…