Closed raxod502 closed 8 months ago
feels more like a bug with ncc than with the package? require("@octokit/plugin-throttling")
doesn't work because it's an ESM module now, try import("@octokit/plugin-throttling")
Other users have experienced issues where tooling cannot find the module, and adding in a main
field has helped them
See https://github.com/octokit/core.js/pull/662
If require
does not work, should the documentation (which says to use require
) be updated?
feels more like a bug with ncc than with the package?
Note that ncc is not involved in the bug report here; I simply installed the package through NPM and tried to load it with require
.
Yes, the docs need updating, but again, you should read the release notes as you seem to be upgrading this package
Fixed by #679
Thanks - I expect this will save people a lot of time with troubleshooting in future.
When installing the latest version of the package in a new
package.json
with Node.js 20 LTS following the directions in the README:See also https://github.com/vercel/ncc/issues/1167.