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

Better esm support #74

Open
OmgImAlexis opened this issue Dec 2, 2019 · 2 comments
Open

Better esm support #74

OmgImAlexis opened this issue Dec 2, 2019 · 2 comments

Comments

@OmgImAlexis
Copy link

OmgImAlexis commented Dec 2, 2019

I noticed in #27 esm support was added but only in the cases of require = require('esm')(module);.

What doesn't seem to be supported is this.

const _require = require('esm')(module);
const myModule = _require('my-module');

@guybedford any chance you could help on this?

@OmgImAlexis
Copy link
Author

I haven't checked but I don't believe this supports passing the options object to esm either.

For example:

const options = {};
const _require = require('esm')(module, options);
const myModule = _require('my-module');

@OmgImAlexis
Copy link
Author

OmgImAlexis commented Dec 2, 2019

Wouldn't it make more sense to just look for and replace require('esm') while ignoring the rest?

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

No branches or pull requests

1 participant