The module in question requires this, which works for dev
import { RRule, RRuleSet, rrulestr } from 'rrule'
This results in the following error from npm run build
import { RRule } from "rrule";
^^^^^
SyntaxError: Named export 'RRule' not found. The requested module 'rrule' is a CommonJS module,
which may not support all module.exports as named exports.
CommonJS modules can always be imported via the default export, for example using:
import pkg from 'rrule';
const { RRule } = pkg;
Then, when I do the import pkg like it suggested, that works for build but not on dev.
The normal import worked for months. About a month ago it stopped working and required this constant switcharoo between build and dev.
As far as I can tell, there were no updates to the module, os or environment. I'm on WSL2 ubuntu, but I have updates turned off. The package.json has not changed, I verified thru git file history.
So my questions are: