Open Quanyails opened 1 year ago
Hello @Quanyails Thanks a lot for the message! And thanks for letting me know about this issue.
Unfortunately I haven't been able to find a good solution. Possibly it could be fixed if I used lodash-es
instead of lodash
, but I cannot do that as I am exporting the library both as CommonJS (CJS) and as ECMAScript modules (ESM).
I think one solution can be for you to use CJS in your project. Here is a PR that does the change https://github.com/Quanyails/cap-scratchpad/pull/1. Be aware, that's maybe not something you want to do, as ESM is supposed to be "the future".
I will leave this issue open an maybe give it another attempt later.
Hi @lzear! 👋 Yeah, I was hoping I didn't need to switch my project to use CJS imports. If there's no elegant solution, though, I'm content to use workarounds. Thanks for looking into this issue, in any case.
Hi @Quanyails
I think I finally fixed it :sweat_smile: From version 3.0.0, your workaround is probably not needed https://github.com/lzear/votes/releases/tag/votes%403.0.0
First, I just want to say thanks for publishing this library! This is a high-quality resource for running different types of voting algorithms. I'm interested in using this library for hobby purposes.
I'm trying to run this library from a Webpack config, but I'm running into error messages that resemble the following:
The Webpack config I'm using comes from the official Webpack + TypeScript docs.
I'm able to resolve this issue by following these steps. Can we provide an out-of-the-box fix for this, though?
Additional information: