The battle between good and evil begins in the realm of shadow, where the precise locations of good and evil are not clearly recognizable.
But at the moment that certainty exists, at the moment that there is a face-to-face confrontation and a person cries out upon recognizing the evil, "You are evil, wicked, disgusting, loathsome, and abhorrent!" the battle has been decided, the lamp has been lit, and the shadows fade.
At the moment that a person overcomes the illusions, God completely removes the evil and its power of misdirection.
When it ceases to mold itself into the shapes of the world, it no longer possesses form and immediately dissipates before the divine light.
–Rabbi Adin Steinsaltz
From Understanding the Tanya, Chapter 29 by Rabbi Adin Steinsaltz