ESP32 is a term that is often used very broadly. If you want to be accurate, ESP32 is a very specific integrated circuit that contains a lot of stuff needed for computation and packaged in a single chip made by Espressif. This chip, usually called SoC/MCU contains the CPU, RAM, ROM, and other peripherals, even wireless communication and encryption primitive.
ESP32 itself contains the following spec:
Dual core 32-bit CPU with clock speed up to 240MHz
520KB of SRAM
448KB of ROM
Now, for comparison, the Apollo programs consist of a lot of systems. But arguably, the computer that is responsible to make the landing possible is the guidance computer.
Let’s take a look at the spec from wikipedia:
15-bit CPU with a clock of 2.048 MHz
2048 words RAM (2048×15 = ~30KBit)
36864 words ROM (~553KBit)
That alone should give you an idea of how powerful computers have come to. Not to mention the size difference (ESP32 only around 5mm×5mm), power consumption, and a lot of other factors.