AUSTIN, Texas (Reuters) - A U.S. district judge on Wednesday struck down parts of a Texas law that would ban the most common type of second-trimester abortions in the state, after plaintiffs argued the procedure was safe, legal and necessary for women’s health.

U.S. District Judge Lee Yeakel in Austin issued a permanent injunction against the provisions that were in legislation known as Senate Bill 8 (SB 8) and set to take effect this year, saying they “are facially unconstitutional.”

He added: “The act intervenes in the medical process of abortion prior to viability in an unduly burdensome manner.”

Texas, the most-populous Republican-controlled state, has been at the forefront of trying to impose abortion restrictions. In recent years, such legislation by the state has generally been struck down by federal courts that have often said the measures are unconstitutional because they place an undue burden on women and do not promote public health.

Republican Texas Attorney General Ken Paxton said his office had appealed the decision, adding SB 8 was lawful and protected “unborn human life from ghastly dismemberment abortions.”

Yeakel, appointed by former Republican President George W. Bush, wrote that “dismemberment abortion” was not a medical term used by physicians and the intent of the act was to ban the dilation and evacuation procedure. He said that resulted in an undue burden on a woman’s right to have an abortion.

While dilation and evacuation is used in most second-trimester abortions, nearly 90 percent of all abortions are performed in the first trimester, according to the Guttmacher Institute, a research group that supports abortion rights.

“This is a huge win for Texas women and families,” said Amy Hagstrom Miller, president and chief executive of Whole Woman’s Health, one of the plaintiffs in the lawsuit.

Similar bans in other states including Alabama, Arkansas, Kansas and Oklahoma have also been struck down by courts.

The Texas law refers to the procedure as “dismemberment abortion,” in which a combination of suction and forceps issued to bring tissue through the cervix.

Opponents of the law say that after about 15 weeks of pregnancy, it is the safest method of abortion.

Texas lawmakers proposed SB 8 after the U.S. Supreme Court in June 2016 - in what legal analysts called the strongest endorsement of U.S. abortion rights in more than two decades - struck down a different Texas abortion law that imposed strict regulations on doctors and facilities.