Similar for me. In the moment, talking about dying doesn't feel like a joke. After you've seen enough and come out the other side, death doesn't feel significant or threatening enough to have to worry about joking about. I feel like those who joke about killing themselves have either never felt like doing it or have confronted it and moved on.
And suicide jokes are probably best kept for groups where you know where people are. A lot of people mask being suicidal by joking around and putting a lot of work into being upbeat, often surprising those who only know them superficially when they commit suicide.