If you read about Hall effect sensors — the usual way to detect and measure magnetic fields these days — it sounds ...
This will not work with Arduino IDE 1.6.5 (or below) or with non ESP32-S2/S3 devices (e.g. Arduino UNO, Arduino MEGA, etc.). To use this library you need to have Arduino core for the ESP32 installed.