commitizen / commitizen/cz-conventional-changelog

mock-require is deprecated

Open
#225 0 comments 0 reactions 0 assignees View on GitHub
esm
Dominant language
JavaScript
Stars
793
Forks
444
PR merge metrics
No merged PRs in 30d

Description

Someone contributed a dependency that relates to require and mocking. Sadly, this dependency is long deprecated. Proxyquire might or might not help. Looks like the author recommended to use it, but unclear if it works for this use-case.

Of course a lot of the code in commitizen is not ideal given newer versions of node and the evolution of ESM.

A few options:

- Continue to have mock require, remove whatever code seems to be blocking test right now and yolo
- Find a suitable alternative and get it working but keep using require.
- Stop using require, move to esm. Drop older node support. More like a rewrite.

Not sure any of these really speak to me. I tend to not want to keep supporting anything older than 18 though at this point.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.