fast-geoip icon indicating copy to clipboard operation
fast-geoip copied to clipboard

__dirname undefined

Open y-nk opened this issue 10 months ago • 3 comments

when deploying on edge, __dirname is not defined, also it's said as a best practice to bundle all js in a single file to optimize cold start. hence, the code in here:

https://github.com/onramper/fast-geoip/blob/a5d3c6b4056cc2a1bf066e7af5bb8440c711e040/index.ts#L12

breaks execution of a lambda@edge using this package.

i was wondering if you had any suggestion for a suitable workaround?

y-nk avatar Sep 13 '23 14:09 y-nk