The following commentary is from The Oxford Bible Commentary. The bolded portion is my emphasis:
vv. 21-2, the evangelist underlines that Jesus himself is a Jew (cf. v. 9) and that salvation comes to the nations through the Jews (cf. Isa 40:1-31 and the synoptic tradition). But at the same time Jesus questions the two places of worship, Mt. Gerezim and Jerusalem. vv. 23-24, ‘in spirit and truth’ is a double phrase with a single sense, similar to ‘Spirit of Truth’ in 14:17; 15:26; 16:13. It means an openness towards the Spirit whom Jesus gives (3:6; 4:14) and the truth that he reveals (1:14, 17; 14:6). ‘God is spirit’ has nothing to do with the Enlightenment description of the nature of God, but underlines that God will give his Spirit through his Messiah.
Rene Kieffer, “John”, The Oxford Bible Commentary. Oxford University Press, NY, 2001. pp. 968.