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

Does not resolve dependencies loaded via module.createRequire #430

Open
timfish opened this issue Jun 26, 2024 · 0 comments
Open

Does not resolve dependencies loaded via module.createRequire #430

timfish opened this issue Jun 26, 2024 · 0 comments
Labels
bug Something isn't working good first issue Good for newcomers

Comments

@timfish
Copy link
Contributor

timfish commented Jun 26, 2024

The current recommended way to load native node modules from ESM is via module.createRequire but @vercel/nft does not resolve and include paths that are loaded this way:

import * as module from 'node:module';

const req = module.createRequire(import.meta.url);
const lib = req('./lib.node');
@styfle styfle added bug Something isn't working good first issue Good for newcomers labels Jun 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

2 participants