Story highlights During the presidential campaign, both McConnell and Ryan argued that there were smarter ways to secure the border

The switch marks the reversal of several years

Washington (CNN) When President Donald Trump first proposed spending billions of dollars to build a massive wall on the US-Mexico border, Republican leaders weren't immediately thrilled with the prospect.

Now, Trump is getting the hearty backing -- or at least strong cooperation -- of rank and file Republicans and GOP leaders to build the border wall many of those same officials once called an overly costly and insufficiently effective border security measure.

House Speaker Paul Ryan and Senate Majority Leader Mitch McConnell said Thursday at the Congressional GOP retreat in Philadelphia that they would push ahead with legislation to fund Trump's wall, which they estimated would carry a $12 billion to $15 billion price tag.

Just weeks earlier, McConnell was dodging reporters' questions about whether he'd support a wall. And during the presidential campaign, both McConnell and Ryan argued that there were smarter ways to secure the border.

The switch marks the reversal of several years during which Republicans have distanced themselves from proposals calling for a physical barrier at the border in favor of more advanced technology and a broader focus on comprehensive immigration reform. And it raises the specter that Republicans could soon get on board with many of Trump's hardline policies on immigration -- like mass deportations -- and other issues, like trade.

Read More