I think it's a bit more complicated than that. The perspective you mention was certainly a widespread one, but like most new perspectives it coexisted with the older one as well, which was a more Enlightenment-era belief in the harmony of natural philosophy with religion and science as a pious pursuit. Just think of all those Victorian clergymen naturalists.
Apologies in advance, if I go a bit into the long form here.
Sure, but there's a time element there, and by common 19th c. continental European consent already in the early part of the century, the British, and their Amercian cousins, were regarded as peculiar in their insistance on mixing religion and science like that.
It's like the old story of Napoleon asking the astronomer Laplace (the mathematical bulldozer who developed his cosmology jointly with Kant, and crunched all the numbers Newton couldn't be arsed to, since he had all this alchemy to sort out) where god fit into his system, to be told by Laplace, that there was no need for any such hypothesis in it. Whether the story is actually true or not, it wouldn't be told in a British context from the same period.
And even in the UK I'd say the clergymen naturalists (like Sedgewick, who was a frikkin bishop-geologist, Norwich iirc) were going out beginning from around 1850. The future of science in the UK did belong to the Huxleys, the first professional scientist in the UK, who had to invent his own profession and was seriously at loggerheads with the CofE (which insisted that a man without religion by necessity had to be a virtuless scoundrel, meaning Huxley lived his life as an object lession in irreligion not making you a Bad Person per se).
Someone like Huxley, in his biographer Adrian Desmond's expression, broke the British upperclass moratorium between clergy and the "gentlemen of science" (wealthy and leisured, think Lyell and Darwin, who even discussed the misfortune of a clever chap like Huxley not being wealthy and leisured, like them, but having to work for a living, cutting into his usefulness as a researcher) of "trading intellectual arms across the aisle" to the lower classes. Certain segements of the British working man absolutely loved Huxley's irreverent materialism, since he was indirectly telling them church authority was a sham. And while the CofE naturalists were on the out from mid 19th c., the "gentlemen of science" had a bit more staying power, but were constantly falling behind continental Europe's systems of national education and new emphasis on scientific research (the French in the first half of the 19th c. and more importantly the Germans in second). From the British university reforms to catch up in the 1880's the gentleman scientists had also had their day compared to the academic professionals in Huxley's mold.
And not focusing on the UK, the pattern was still similar that from around 1850 the lines were drawn sharper. French republicanism took hold there with the revolution in 1848, and that republicanism was directly anti-church, as in opposed to Rome. (Though that did mean we get interesting groups of oppositional French Catholic monarchist scientists around as well, and neither side ended up much liking the Second Empire anyway.)
While in Germany from around 1850, along with the liberal demands for unification (since it didn't work out the bloody revolutionary way in 1848), there was also a generation of new Young Turks mixing their liberal politics and science, specifically gunning for the early 19th c. German idealistic "Naturphilosophie" in favour of mechanistic materialism directly and aggressively opposed to religion. Ludwig Büchner wrote their statement of program (iirc in 1854) with the title "Kraft und Stoff", "Power and Matter". Aside from Büchner, these were individuals like the young Rudolf Virchow (his analysis of the conditions of Silesian miners is still a classic in social-medicine-as-politics-by-other-means, later Reichstag leader of the liberal opposition to Bismarck, who even wanted to try killing him in a duel to get rid of the man), the anatomist Carl Vogt (condemned to death in his absence for his activities in 1848 and relocated to Switzerland), and Ernst Haeckel, the Monist, and Darwin's German bulldog.
It wasn't really a coincidence either that Bismarck, in his usual way of trying to co-opt the issues of the oposition to his kind of German Empire, ended up declaring the "Kulturkampf" against in particular Catholicism, with the Jews thrown in for good measure. ("Gegen Rom und Juda!") It did leave Lutheran Protestantism as sort of the default religion least problematic to 19th c. scientists, and many saw it precisely like that. Then again it was pretty seriously de-clawed from the fire-and-brimstone-Old-Testament kind of thing it had previously been in its history.
So, yes certainly the 19th c. was every bit as divided on most issues as our present times. However I would still say that there was a 19th c. ongoing gradual professionalisation and institutionalisation of science and research in the hands of new professional groups dedicated to it. And these groups had at least a reasonably consistent attitude (with exceptions certainly, there always are) towards traditional religion, ranging from verbally violent confrontation to at least marginalising it. A lot of the bad-mouthing of organised religion from the 19th c. did after all come from this group. They weren't necessarily arguing in good faith either, but they were in some ways strikingly successful in giving religion a bad name.
And just FYO, my specific interest in these things circles around 19th c. discussions between self-styled scientists (doctors, anatomists, zoologists mostly) about human origins and race - where it's palpably obvious that religion was a major influence, with the aggressive ideologues of race claiming to be especially scientific for having a jaded view of non-European humanity, while slamming their adversaries (more generous towards non-western man) for simply being stuck in old patterns of irrational religious thinking. It's an intersting situation in the history of science, since the bunch aggressive towards non-whites tend to be traditional Great Men of Science. Except of course today we think they got that one just plain wrong. While their adversaries, traditionally written of as religious old fogies, today can be seen to have been making some excellnt points, regardless whether part of their motives were religious or not.