Generally I think it's pretty bad. Like it's not your secret to tell and it's such a breach of trust. That being said, I've done it before
One of my friends came out to me and told me he had a big crush on me. So I decided to tell my entire high school! I was so terrible back then. He hated me for a while, but eventually said it was a lot easier that everyone already knew instead of having to tell everyone. Then we dated for like a year