ashtuchkin / iconv-lite

Convert character encodings in pure javascript.
MIT License
3.08k stars 282 forks source link

lazy-load encodings using a more reliable path #310

Open yogo1212 opened 1 year ago

yogo1212 commented 1 year ago

the current working directory might not be the directory containing the code. when that is the case, the loading fails. use the __dirname variable from nodejs to search relative to the executing file rather than the working directory of the process.

yogo1212 commented 1 year ago

Should fix https://github.com/ashtuchkin/iconv-lite/issues/118