Would work fine. The ESP8266 was preferred by me as it’s cheaper and I have a number of them spare, but if you already have an ESP32 sitting there then definitely take advantage of that. I think the ADC used by the ESP32 may even be a little more accurate depending on the board used.