How to move 1wire sensors (D18S20) from local GPIO to ESPHome

Hi there,
I am using a bunch of 1wire sensors (D18S20s) on my local raspberry pi running home assistant via the 1wire integration (using local GPIO). With the update to 2022.6 I would like to move these sensors to one of my ESP32s running ESPHome. How can I move the configuration from my exisiting Pi to ESPHome by keeping the naming and sensor history?

My current system:
Home Assistant Core 2022.5.5
Home Assistant Supervisor 2022.05.3
Home Assistant OS 8.1

BR,
hoehm

Thanks tom_l!
This one I know. I also run quite some ESP32s with 1-wire sensors via ESPHome and therefore know the configuration for new devices. My question is more how to migrate and move sensors to ESPHome by keeping the history, location, name labeling, etc. It is maybe not an 1-wire specific question and more about moving entities from one device to another.