Texas won’t allow schools to use state funding to educate immigrant children while they are being housed in federal detention — something that would have cost millions, the Texas Education Agency (TEA) said.

The education agency told the Austin-based charter school group Southwest Key, Promesa Public Schools, that local schools that want to serve migrant students in federal custody cannot “do so with state education funding,” the Houston Chronicle reported.

Southwest Key, one of the largest nonprofits operating shelters for migrant children in Texas, said the agency’s stance jeopardizes partnerships the shelters have formed with at least two traditional school districts, one of which would have funneled millions of Texas tax dollars.

“I think the ones that ultimately are affected adversely are the youth that are in the shelters,” Salvador Cavazos, the nonprofit’s vice president for education services told the paper.

“Because we’re in a partnership, we would have been able to provide additional resources, partner with credit-bearing institutions, provide grades and help them achieve credits go to other public schools.”

Texas officials say it falls under the legal obligation of the federal government to educate the migrant children.

This comes amid the debate of what to do with minors who cross the border illegally.

U.S. Immigration and Customs Enforcement requires school-age children in shelters to receive at least six hours of structured education during the week.

Related: Illegal Immigration Now Far More Dangerous Than Five Years Ago

Texas officials say schools still could voluntarily provide help to shelters.

Who do you think would win the Presidency?

By completing the poll, you agree to receive emails from LifeZette, occasional offers from our partners and that you've read and agree to our privacy policy and legal statement.

But school leaders across the state say their schools have been dealing with declining state funding for years, which makes it impractical to pay to provide services to students who aren’t technically enrolled in their districts.

The Supreme Court has previously ruled that all children — regardless of immigration status — are entitled to a public education.

President Donald Trump signed an executive order that stopped family separations at the border in June.

The Supreme Court has previously ruled that all children — regardless of immigration status — are entitled to a public education.

The Associated Press contributed to this Fox News report, which is used by permission.

Read more at Fox News:
Louis C.K. Performs at NYC Club for First Time Since Admitting to Sexual Misconduct: Report
Eddie Murphy Is Expecting 10th Child: Report
May-December Romances