Get breaking news alerts and special reports. The news and stories that matter, delivered weekday mornings.

An outbreak of measles that has sickened 51 people is stretching public health departments thin and costing hundreds of thousands of dollars, officials said Wednesday.

Minnesota Health Commissioner Ed Ehlinger asked the state Legislature for $5 million for an emergency fund to deal with the outbreak and other infectious diseases, such as Zika and syphilis.

15-month-old August Goepferd gets a measles, mumps and rubella booster shot at a clinic at Children's Minnesota in Minneapolis. Amy Forliti / AP

"In recent months, state and local public health officials have had to respond to a series of infectious disease outbreaks including multi-drug resistant tuberculosis, hundreds of new cases of syphilis, and now, the largest measles outbreak the state has faced in nearly 30 years," Ehlinger said in a statement.

Measles outbreaks are especially costly to deal with because of the intensive follow-up that is needed for each case. Measles is one of the most infectious viruses known, and it can hang in the air of a room for two hours after an infected person leaves.

Ninety percent of people who are not vaccinated will catch measles if they are exposed. That means state and local health officials have to track down hundreds of people for every confirmed case.

The Department of Health says 47 of those infected are confirmed to have been unvaccinated and one person had only one of two recommended doses. Two people had received both recommended doses.

"We have had 70 staff at the state Health Department working on this response," said Kris Ehresmann, the department's infectious disease director.

Related: Measles and Fear Put These Kids in the Hospital

She said the state and Hennepin County, which covers Minneapolis, had checked on 8,000 possible exposures to measles.

While most cases are mild, measles can kill, and it often puts people into the hospital. At least 11 children have been hospitalized for pneumonia, dehydration and fever.

Let our news meet your inbox. The news and stories that matters, delivered weekday mornings. This site is protected by recaptcha

"This is a hugely expensive outbreak," Ehresmann told NBC News. The state spent $207,000 in the first three weeks of the outbreak, she said.

"Not only are there health costs for treating children. There are economic costs for their families, and there are costs to the public health system," she added.

Related: Measles Outbreak Caused by Vaccine Skeptics

Unvaccinated kids cannot go to school or day care, which means someone has to stay home from work to care for them.

"We have had staff working every single weekend since April 11," she said. "The new cases will take us to Memorial Day. That's because you must wait 21 days since the last case onset until you can feel things are really over."

The Health Department blames years of pushing by anti-vaccine activists who targeted the Somali immigrant community, telling them that the measles, mumps and rubella (MMR) vaccine might be dangerous and urging them to skip or delay vaccinating their kids.

"Vaccine-preventable outbreaks are extraordinarily expensive."

"This is really an unnecessary outbreak," Ehresmann said.

"We know that we'll get one or two cases of measles in a state because it is occurring in other parts of the world," she said. Tourists and travelers can come from any place infected — but the infection won't spread unless there are unvaccinated people to catch it.

Related: New GOP Budget Would Cut Public Health Fund

"Significant threats to public health are becoming more frequent and costly," Ehlinger said. Screening pregnant women and travelers for Zika virus, which can cause severe birth defects, also stretched his department.

"Minnesotans rightly expect a rapid and effective response to these threats, but current state funds lack the flexibility needed to deal with emergent disease threats," Ehlinger said.

State and local health departments have been complaining for years that their resources are stretched, even as they lay off more staff.

"Vaccine-preventable outbreaks are extraordinarily expensive," said Laura Hanen of the National Association of County and City Health Officials.

Related: U.S. Not Preparing for Next Biothreat

"We have seen our public health workforce decline since the 2008 recession," Hanen said. "While we have seen an economic recovery, it is going to take decades at the rate they are hiring to gain back the staff that they've lost."

But funding is under threat from Trump administration, which has asked Congress to cut funding for public health and biomedical research.

"We are in very tight budgetary times, and we fully expect that with the president's budget, there will be deep cuts in there," Hanen said.