Not everyone has gas pipes in his flat around. Electricity is more common. I was looking for some similar device for my bathroom where you do not need constant warm water. On Europe now gas is much more expensive than electricity. For heatpump you would need an additional part outside of the building connected to the heater. It is very difficult and with a lot of hassle to install it after a building has been built.
Xiaomi has a deserved reputation for low quality. Generating heat via electrical resistance is the most costly and least efficient method. Natural gas or heat pumps are far less expensive and environmentally friendly to operate.
Xiaomi has unveiled the Mijia Smart Kitchen 7L S1 water heater, which is now on sale in China. The gadget has 2,000 W heating power and can produce up to 42 L of hot water continuously. You can control the device with Xiao AI voice commands or the Mijia app and connect the water heater to other smart home gadgets.