-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Emotion 11 is trying to use previous styled-base dependency when bundling with Babel #2453
Comments
this appears to be a issue others have had in the past moving into 11, I am currently just rolling back to release within 10 due to the complications with using 11 I have found, but it certainly could be better handled especially for instances where people are using TS. honestly the team on this is awesome, this is no real strike against them, but it does seem like a legitimate problem, especially when generic imports with yarn will automatically position you to 11 despite the dependency issue still being present for enough to see a number of bug reports. this is a link to a comment about it in the 11 bug thread, but there are a number of those comments. #1606 (comment) again, love the fact people work so hard on things like this that many use for free. Simple fix for me tbh. |
This might mean that you are using |
I had this issue using no emotion babel plugin. Using @emotion/babel-plugin fixed it. |
@ciaranschutte Are you using Storybook? I believe Storybook is still using Emotion 10 internally. |
When I bundle my library that has the below dependency versions, the component is trying to import the older version of styled-base rather than the latest styled/base.
This causes a problem when trying to install this library in a peer application. I get an error saying it cannot find
@emotion/styled-base
due to it not being installed as the new version 11 does not require it.I did notice within this library that
styled-base
is being installed as a dependency, but I assume thats because one of my storybook modules has it as a dependency.It seems like this is causing a confusion when bundling?
Environment information:
The text was updated successfully, but these errors were encountered: