Goals from Jimmy Kebe, Jobi McAnuff and substitute Noel Hunt secured the Royals their eighth successive win and saw them move to within just three points of an automatic promotion place. Andy King pulled a goal back for the Foxes in the 79th minute but it was too little, too late.
McDermott said: "We had to dig in. Unusually for us, we played like the away team. Leicester showed their quality but we hit them on the break for the first and then got the second, which was massive.
"Jimmy Kebe was sensational. He was creative, strong and powerful and did his job for the team as they all do.
"I can't put my finger on the reasons for our run of success. It's a little bit of everything. The players have created a great group environment. I try to do my best for those not playing. An example is Noel Hunt, who came back after being out injured and scored.
"I am not looking at second place in the table I am just looking at our next game at Leeds on Friday night. We are looking to do well there and that's all I am looking at."