Skip to content
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

feat: support deferring to the underlying 'require' implementation if Module._resolveFilename fails #59

Merged
merged 7 commits into from
Jan 17, 2023

Conversation

trentm
Copy link
Member

@trentm trentm commented Jan 12, 2023

There might be an already monkey-patched 'require' that knows how to
resolve a special identifier. This is needed to use
require-in-the-middle with 'azure-functions-nodejs-worker', which
patches 'require' to support require('@azure/functions-core').

…Module._resolveFilename fails

There might be an already monkey-patched 'require' that knows how to
resolve a special identifier. This is needed to use
require-in-the-middle with 'azure-functions-nodejs-worker', which
patches 'require' to support `require('@azure/functions-core')`.
@trentm trentm self-assigned this Jan 12, 2023
@trentm trentm requested a review from watson January 13, 2023 16:58
index.js Outdated Show resolved Hide resolved
index.js Outdated Show resolved Hide resolved
test/already-monkey-patched-require.test.js Show resolved Hide resolved
@trentm trentm requested a review from watson January 16, 2023 20:20
Copy link
Contributor

@watson watson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Awesome! 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants