-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Can't import CommonJS module from dist/index.js:133
#1
Comments
Changing that line 133 to the suggested: import pkg from 'rrule';
const { rrulestr } = pkg; seems to solve the issue, but I know that that's not a good long-term fix. |
Interesting error, I haven't had this before. I'm not entirely sure what your setup is and if you use tools such as I tried around a fair bit and am not if I correctly fixed the issue, but here are a few findings I made:
I'd be interested in the exact setup (mostly how bundling/transpiling is done in your project) Edit: I noticed that those changes don't really fix your problem which I just got to being able to reproduce, but fix issues I had on the way of trying to get there |
Testing around a bit more I stumbled upon this issue. It seems like your fix is the most easy solution, even though it isn't the most elegant; I'll go ahead and introduce all of the fixes required |
|
Thanks for the lightning-quick responses! Will have some time to test within the next few days and let you know! |
@JaninaWibker, confirmed working on:
and Thank you! |
Hi! Thanks for the library. After making sure that my
tsconfig.json
contains the following:a mere import in my
src/index.js
script of (with an invocation ofnode src/index.js
(after TypeScript compilation)) of the following:gives me the following error:
Am I missing something additional, or is there a deeper error here?
Thank you!
The text was updated successfully, but these errors were encountered: