Taiwan becomes first Asian nation to legalize same-sex marriage originally appeared on abcnews.go.com

Lawmakers in Taiwan voted in favor of a bill legalizing same-marriage Friday, making the self-governing island the first Asian country to do so.

Tens of thousands of demonstrators, gay rights supporters and dissenting protesters packed the streets outside the parliament building in Taipei in the rainy morning hours, awaiting the crucial vote.

Taiwan's constitutional court ruled in 2017 that same-sex couples had the right to marry and gave the government a two-year deadline to amend the constitution with a new law to guarantee it.

The momentum suffered a setback this past November when 67% of Taiwanese voters rejected the notion that Taiwan’s civil code “should be used guarantee the rights of same-sex couples to get married,” reflecting the conservative traditional values still entrenched in Taiwan despite its reputation for being progressive on gay rights.

(MORE: Mormon church opposes LGBT nondiscrimination measure)

Opponents of same-sex marriage began to push back and dulled the political will of some lawmakers over fears of repercussions in the general election next year.

Taiwanese President Tsai Ing-wen, who faces a tough re-election fight, continued to press forward on same-sex marriage, which she publicly supported during her 2016 campaign.

The legislature ultimately voted 66-27 overwhelmingly in favor of an article that would allow same-sex couples to register their marriage with government agencies, enshrining it into law.

“On May 17th, 2019 in #Taiwan, #LoveWon,” Taiwanese President Tsai Ing-wen tweeted after the vote. “We took a big step towards true equality, and made Taiwan a better country.”

PHOTO: TThousands of gay rights supporters gathered outside the parliament building celebrate after Taiwan's parliament voted to legalize same-sex marriage on May 17, 2019 in Taipei, Taiwan. (Carl Court/Getty Images) More

PHOTO: Same-sex marriage supporters celebrate after Taiwan became the first place in Asia to legalize same-sex marriage, outside the Legislative Yuan in Taipei, Taiwan, May 17, 2019. (Tyrone Siu/Reuters) More

Media executive and LGBTQ activist Jay Lin told ABC News that he was "so happy to be living in Taiwan and witnessing this day."

Lin had briefly joined his fellow activists in front of the legislature building before heading to work.

“I was nervously checking the phone during a lunch meeting with clients who came from abroad and erupted into jubilation after they left and I saw the results," he said.

Lin went straight back to the office and began celebrating with his colleagues, many of whom have also worked on the same-sex marriage fight for the past three years.

PHOTO: People celebrate after Taiwan's parliament voted to legalize same-sex marriage on May 17, 2019 in Taipei, Taiwan. (Carl Court/Getty Images) More

“We just broke out into spontaneous celebration, drinking and hugging,” said Lin.

The Taiwan vote comes as LGBTQ rights in other parts of Asia have come under attack in places countries like Brunei and Indonesia.

(MORE: Anti-gay, anti-Semitic US preacher banned from Ireland)

PHOTO: Map locates countries where same-sex marriage is legal. (AP) More

The law that was passed was weaker than some activists groups had hoped for; there were limitations on adoption rights and restrictions on Taiwanese citizens marrying foreigners from other countries where same-sex marriages are not legal.

The new law will take effect next Friday.