Former President Barack Obama has weighed in after a federal judge in Texas ruled Obamacare “unconstitutional.”

Obama said, in part, in a Facebook post that the ruling "changes nothing for now. As this decision makes its way through the courts, which will take months, if not years, the law remains in place and will likely stay that way. Open enrollment is proceeding as planned today.

“But all of this should also be a reminder that Republicans will never stop trying to undo all that,” Obama also said. “If they can’t get it done in Congress, they’ll keep trying in the courts, even when it puts people’s pre-existing conditions coverage at risk. The only way to convince them to stop trying to repeal this law, and start working to make health care better, is to keep voting, in big numbers, in every election, for people who’ll protect and improve our care.”

Meanwhile, President Trump praised the ruling as “great news for America.”

“As I predicted all along, Obamacare has been struck down as an UNCONSTITUTIONAL disaster! Now Congress must pass a STRONG law that provides GREAT healthcare and protects pre-existing conditions. Mitch and Nancy, get it done!” Trump tweeted.

RELATED: Republicans who voted 'No' on repeal of Obamacare

7 PHOTOS Republicans who voted 'No' on repeal of Obamacare See Gallery Republicans who voted 'No' on repeal of Obamacare Sen. Susan Collins, R-Maine (Photo by Mark Wilson/Getty Images) Sen. Dean Heller, R-Nev. (Photo By Bill Clark/CQ Roll Call) Sen. Lisa Murkowski, R-AK (Photo by Chip Somodevilla/Getty Images) Sen. Lamar Alexander, R-Texas (Photo by Zach Gibson/Bloomberg via Getty Images) Sen. Shelley Moore Capito, R-WV (Photo by Alex Wong/Getty Images) Senator John McCain, R-Ariz. (Photo via REUTERS/Aaron P. Bernstein) Sen. Rob Portman, R-Ohio (Photo via REUTERS/John Sommers II) Up Next See Gallery Discover More Like This HIDE CAPTION SHOW CAPTION of SEE ALL BACK TO SLIDE

The ruling was announced late Friday.

The judge struck down the entire Affordable Care Act “on the grounds that its mandate requiring people to buy health insurance is unconstitutional and the rest of the law cannot stand without it,” notes the New York Times.

More from :

Author of Ohio abortion bill believes court will welcome it 'with open arms'

Supreme Court rebuffs state bids to cut Planned Parenthood funds

Trump joins leaders of Canada, Mexico to sign new trade pact