The position of the four Sunni schools and the scholarly tradition for fourteen centuries is that sexual relations are lawful only within marriage between a man and a woman, and that same-sex acts are sinful, as the Quran says when it tells the story of Lot's people. Scholars distinguish between an inclination and an act, and point to the saying of the Prophet ﷺ that Allah has overlooked for his community what their hearts whisper to them as long as they do not act on it or speak it, and the Quran says that Allah does not burden a soul beyond its capacity. So the test is what a person chooses to do and not what he or she feels. Muslims who believe this should be honest that it asks a lot of someone who is gay, because for them it means a life of abstinence, and the same standard of chastity applies to unmarried straight Muslims too. That calls for support from the community, not rejection.
How people are treated is a separate matter, and here Islam is clear. The Quran tells believers not to mock one another, says Allah has honoured all the children of Adam, peace be upon him, and commands justice even toward people you dislike: 'Let not hatred of any people seduce you that ye deal not justly.' Islam also tells believers not to spy, and the Prophet ﷺ said that all of his community will be pardoned except those who broadcast their sins, so private struggles are to be kept private and not exposed. Classical law set a very high standard of proof, and any worldly penalty belonged to a court, never to individuals. Violence, harassment and vigilantism against gay people have no basis in Islam, and Muslims who commit them are acting against their own religion.
Some contemporary Muslim writers, mostly in the West, argue for different readings of the texts, but this is not the position of mainstream scholarship. Harassment and violence against gay people, which happen in some places, are not part of the teaching of Islam. If you are a Muslim who experiences this struggle, you are not outside the mercy of Allah, and you do not need to announce it, nor to carry it alone: speaking to a trusted and kind counsellor or scholar is a good first step. If you are not Muslim, the Muslim belief about sexual ethics is a religious position about conduct, and it is not an invitation to dislike or harm anyone.