Are all-foam mattresses as good as spring ones?

Thanks. We already went ahead and bought a more traditional spring one, but good to know for the future.