Skip to content

[BUG] Package fails to import on Next 13 #887

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

Closed
brunocangs opened this issue Jan 3, 2023 · 3 comments
Closed

[BUG] Package fails to import on Next 13 #887

brunocangs opened this issue Jan 3, 2023 · 3 comments
Labels

Comments

@brunocangs
Copy link

brunocangs commented Jan 3, 2023

Describe the bug
Next 13 tries to import the package as an ES Module as defined by the type: module field in package.json but fails, with an error as the main file is .cjs.

Version of Package
v5.3.3

To Reproduce

  • Create a new NextJS app with create-next-app
  • Install react-tooltip
  • Setup the package and add a tooltip to the pages/index.ts file.

Expected behavior
The package's type and main should match their type

Screenshots
image

Desktop (please complete the following information if possible or delete this section):

  • OS: MacOS 13.0.1
@brunocangs brunocangs added the Bug label Jan 3, 2023
@danielbarion
Copy link
Member

🤦🏻‍♂️

This makes sense, can you do a PR, please?

Thanks for the report!

@itsikcircle
Copy link
Contributor

I've been facing the same issue, and send a PR here #888

@danielbarion
Copy link
Member

PR merged and released.

Thanks everyone!

https://github.com/ReactTooltip/react-tooltip/releases/tag/v5.3.4

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

No branches or pull requests

3 participants