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

Not compatible with Jest ESM #555

Open
jasperlin451 opened this issue Dec 4, 2023 · 1 comment
Open

Not compatible with Jest ESM #555

jasperlin451 opened this issue Dec 4, 2023 · 1 comment

Comments

@jasperlin451
Copy link

Describe the bug

When trying to upgrade my project to be fully ESM, I run into

    SyntaxError: The requested module '@fortawesome/react-fontawesome' does not provide an export named 'FontAwesomeIcon'

This should be fixable by updating the following lines:

"main": "index.js",
"module": "index.es.js",
"jsnext:main": "index.es.js",

to use the modern Node.js packaging standard.

{
  "type": "module",
  "exports": {
    "import": "./index.es.js",
    "require": "./index.js"
  }
} 
@dhwang
Copy link

dhwang commented Mar 6, 2024

@jasperlin451 Maybe create a PR for "This should be fixable by updating the following lines:" ?

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

2 participants