While Kafka was attending elementary school between 1889 and 1893 Prague had no electricity. By the time he started his first job in 1907 Prague not only had a full fledged power grid, but had electric trams, telephones, and movie theaters. And, of course, electric street lamps. Even, a few years later, cubist street lamps.
Kafka, however, didn't directly reflect this technological revolution in his fiction. Mention is made, to be sure, of electricity. In "The Metamorphosis," for example, we learn that, as Gregor Samsa lies in his bed, just recently metamorphosed and about to try out his feelers, "the electric lights in the street cast a pale sheen here and there on the ceiling and the upper surfaces of the furniture, but down below, where he lay, it was dark." The use of electricity is perhaps most notable in "In the Penal Colony," where "both the bed and the inscriber," of the "peculiar apparatus" that is at the center of the story, "have their own electric batteries. The bed needs them for itself, and the inscriber for the harrow. As soon as the man is strapped in securely, the bed is set in motion. It quivers with tiny, very rapid oscillations from side to side and up and down simultaneously. You will have seen similar devices in mental hospitals..."
But Kafka had great discipline as a writer, and knew that he had to keep electricty in the backround. That to do more, to emphasize the technological revolution itself, would tie his fiction to a specific time and place, thereby allowing the reader to start feeling situated in a way that would be inimical to the peculiar universality of Kafka's fiction.