The biggest mistake I made was to introduce a bug on a production app yesterday. So, how did I introduce the bug?
I wrapped my component with an error boundary. In addition to wrapping my component, I accidentally wrapped a dropdown within the error boundary. When the dropdown changes, the error boundary resets (using a key) and everything within it (component tree) is re-constructed. This means that the dropdown componentWillUnmount is called and a new dropdown constructor is called.
So, what was the bug? When I open the dropdown, I remove the body scroll. And when the dropdown is closed, the body scroll is set again (to auto). I forgot to put this logic in componentWillUnmount. As a result, when the error boundary is reset, the body scroll is not reset.
Why is this the biggest mistake of the month? It was embarrassing. After the release, customers used the Dropdown and after that they were not able to scroll the page.
Second, there were multiple technical mistakes:
Overall, I feel a bit guilty because I am a senior developer and should not be introducing these sort of bugs while coding. I am waiting for the day when I write perfect code :)