I bundle with rollup my application (that uses indirectly this module) as an ES module. The bundle fails at runtime because __filename is not defined.
Could the following alternative be added if __filename is not defined?
import { fileURLToPath } from 'url'
const __filename = fileURLToPath(import.meta.url)
Thanks!
mario