Looking for information on the pulse counter module (PCNT) from the ESP-IDF


I try to use the PCNT in Mongoose os so i can count pulses and get the time between pulses. I found some source code on the https://github.com/espressif/esp-idf/tree/c77c4ccf6c43ab09fd89e7c907bf5cf2a3499e3b/examples/peripherals/pcnt

Is there anyone who has implemented this in Mongoose OS and also in Javascript?