This year was one of milestones for state budgets, but the upward swings of 2016 will likely be dampened in the years ahead.

It took almost a decade, but total state spending and revenues finally surpassed pre-recession peaks this year, according to a new survey from the National Association of State Budget Officers (NASBO). Yet more than two dozen states haven’t reached that milestone, a sign of the recovery’s uneven progress after the worst economic collapse in more than a generation.

While fiscal 2016 also marked the highest annual growth -- 5.5 percent -- for total state spending in nearly a decade, it was primarily driven by significant one-time spending increases and technical adjustments in several large states, including New York, Ohio and Texas. The median spending growth rate across the 50 states was 3.8 percent, which is lower than last year’s but slightly ahead of expectations a year ago.

RELATED An Outbreak of Fiscal Responsibility in the States

Looking ahead, spending is projected to slow down even more, to 2.5 percent next fiscal year (which begins July 1 for most states). Revenues are also projected to slow.

Two areas, though, could see increased funding: Medicaid and K-12 education. About two-thirds of states have proposed funding boosts in those areas.

The projected slowdown in spending comes after most states experienced revenue spurts due to federal tax changes in 2013 and a surging stock market in 2015. Still, growth in those years underperformed compared to the decades before the recession hit in 2008.

Generally, states have adjusted to the era of mediocre revenue growth and have been able to rebuild their reserves in preparation for the next downturn, said NASBO executive director John Hicks. Excluding Texas and Alaska, which have outsized rainy day funds, state savings totaled just $3 billion right after the Great Recession, when many were raided to help offset shortfalls. Today, states' savings add up to more than $30 billion, which is roughly what they totaled before the recession.

“They’re in a pretty similar situation now as they were prior to the Great Recession,” said Hicks. “Reserves as a share of current revenues is still slightly lower than in 2008 but quite close.”

Still, the recovery has been uneven. Although total state spending and revenues have surpassed 2008 figures (when adjusted for inflation), 29 states don’t hit those marks. The reasons for that vary and aren’t necessarily signs of a sputtering economy everywhere.

In Rhode Island, for instance, State Budget Officer Thomas Mullaney said revenues in 2016 are down about 1 percent from the prior year, which is what the state expected. But that’s mainly due to a tax cut and rededicating some revenue streams for other purposes.

“Without that, we would be on a slight upswing,” he said.

A few states are notably struggling. Of the eight that are reporting lower revenue this year, six are energy-dependent states, which have been battered by the drop in oil prices and demand for coal. Rhode Island is the seventh, and Illinois -- which has yet to pass a budget for 2016 -- is the eighth.

Three states (New York, Oklahoma and Utah) are projecting revenue declines in 2017. In Oklahoma's case, lower oil revenue may be the culprit, while New York and Utah will be coming off of outsized revenue boosts.