"We've come in for a lot of unfair stick with things that have been in the press, but you've seen that the lads wanted to react," Vardy said."We needed to show that we've got that fight, and win or lose as long as the performance was right, we could hold our heads up high."
Liverpool, which was out of sorts despite a warm-weather training break in Spain, could not match Leicester's energy, intensity and commitment. It remains in fifth place.
Ranieri was dismissed nine months after masterminding one of the biggest sporting shocks of all time by leading the 5000-1 outsider to league glory.
But Leicester have failed to replicate that form. Before facing Liverpool, they had won just five league games and five consecutive league defeats had sent them spiraling down the standings.
There was a strong show of support for the former manager at the game, with fans donning Ranieri masks and holding placards inside and outside King Power stadium. One banner held aloft said "Thank you Claudio for making our dreams come true."
Leicester's players, some of whom have denied any part in an alleged revolt that led to Ranieri's sacking, had their names cheered by fans and appeared up for the highly charged occasion.
The hosts, with Ranieri assistant Craig Shakespeare in interim charge, made a bright start, with Shinji Okazaki forcing Liverpool goalkeeper Simon Mignolet into an early diving save.
Centre-back Robert Huth wastefully headed over from a corner, and Mignolet blocked Vardy's volley as Leicester showed plenty of attacking intent.
The home side's pressure was rewarded, when a through ball from Marc Albrighton sent Vardy away on goal and last season's leading scorer calmly slotted past Mignolet to give Leicester the lead after 28 minutes.
Just 11 minutes later, Leicester fans were on their feet again to acclaim an outstanding goal from Drinkwater, the midfielder sending a dipping volley past Mignolet from fully 30 metres.
Vardy got his second on the hour, when he headed in a Christian Fuchs cross and although Liverpool enjoyed its best spell, after Philippe Coutinho pulled a goal back in the 68th, Leicester held firm.
Whether Leicester moves quickly to appoint a permanent successor to Ranieri or lets Shakespeare make his case to step up remains to be seen.
Nigel Pearson, sacked by Leicester in June 2015 after saving the club from relegation, a move which led to Ranieri's appointment, is among the names linked with the job. Guus Hiddink, Roy Hodgson, Roberto Mancini, and Martin O'Neill are also in the frame.