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

The dist files for CommonJS are not correct #1218

Closed
LitoMore opened this issue May 4, 2023 · 2 comments · Fixed by #1219
Closed

The dist files for CommonJS are not correct #1218

LitoMore opened this issue May 4, 2023 · 2 comments · Fixed by #1219
Labels

Comments

@LitoMore
Copy link
Collaborator

LitoMore commented May 4, 2023

CleanShot 2023-05-04 at 15 10 58@2x

As you can see here https://www.jsdelivr.com/package/npm/@inquirer/core?tab=files&path=dist%2Fcjs, it runs require("./lib/screen-manager.mjs") for importing modules.

This might be related to:

Or we could consider other tools. For example https://github.com/egoist/tsup.

How to reproduce

// Use CommonJS, and run this line
const {input} = require('@inquirer/prompts');
@saracope
Copy link

saracope commented May 4, 2023

Also seeing this issue. Appreciate the quick fix @LitoMore

@SBoudrias
Copy link
Owner

Thanks @LitoMore

The patch are released to NPM.

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

Successfully merging a pull request may close this issue.

3 participants