WASHINGTON (WPRI) — The House voted Friday to pass a bill that would make it illegal to discriminate on the basis of sexual orientation and gender identity.

The Equality Act is the product of five years of work by Congressman David Cicilline, D-Rhode Island, one of the few openly gay members of Congress.

“Today is a historic day for our community but really a historic day for our country,” he said Friday.

It’s the first time Congress has approved comprehensive LGBTQ rights legislation. It was a top Democratic priority and passed with just eight Republicans voting in favor.

“This is an important statement from the government saying, ‘we see you, we value you, we respect you,'” Cicilline added. “Equality and equal justice under law is one of the founding principles of this country.”

The legislation seeks to update the Civil Rights Act of 1964.

“Today, on this day, we have an opportunity to send a message now, to help end discrimination in our country and set all of our people free,” said Congressman John Lewis, D-Georgia, a veteran of the American Civil Rights movement.

While LGBTQ groups say the bill is long overdue, it’s been met with resistance from conservative and religious groups, who say it will hurt women and children and stifle religious freedom.

“[The bill] eliminates safe spaces for women, irreparably harms children, tramples parental rights,” said Congresswoman Vicky Hartzler, R-Missouri.

“It would essentially allow the government to place its hard and unyielding fist inside the church walls to force compliance with the convictions and dictates with the state instead of the church,” said Congressman Ross Spano, R-Florida.

The bill faces a tough road in the Republican-controlled Senate and President Donald Trump said he opposes the bill.