rotemdan / lzutf8.js

A high-performance Javascript string compression library
MIT License
322 stars 26 forks source link

RunningInNodeJS condition #9

Closed amertak closed 8 years ago

amertak commented 8 years ago

Build 0.3.3 broke the condition.

0.3.2 was

LZUTF8.runningInNodeJS = runningInNodeJS;
if (typeof module === "object" && typeof module.exports === "object") {
  module.exports = LZUTF8;
}

0.3.3

if (runningInNodeJS()) {
  module.exports = LZUTF8;
}

Now I cannot use it in webpack build and I am forced to use v0.3.2. Hope it can be fixed.

Thanks for the great library anyway! 👍

rotemdan commented 8 years ago

Thanks for reporting. That was an unintended regression from a refactor I've made in the most recent release. This should be fixed now in 0.3.5.

rotemdan commented 8 years ago

Please let me know if there are other issues you're experiencing.

amertak commented 8 years ago

It is now fixed and it's working great.

Thanks ;) Closing