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

Change the key of a global key (indicating the @emotion/react has been already loaded) to include the major version #1981

Merged
merged 1 commit into from
Aug 21, 2020

Conversation

Andarist
Copy link
Member

In the future, it should be possible to upgrade your own code to Emotion 12 but still use, for example, Storybook based on Emotion 11 without this warning popping up. Actually there might be other problems with such setup and it might not work for some reason (but hopefully it would) - don't want to focus on unknown problems, because I can't imagine how this would potentially break on my own, so this is the least we can do right now until other issues arise in the future.

…n already loaded) to include the major version
@Andarist Andarist requested a review from emmatown August 21, 2020 20:22
@changeset-bot
Copy link

changeset-bot bot commented Aug 21, 2020

🦋 Changeset is good to go

Latest commit: a309c3c

We got this.

This PR includes changesets to release 2 packages
Name Type
@emotion/react Patch
@emotion/jest Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@@ -1,4 +1,5 @@
// @flow
import pkg from '../package.json'
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this is causing the whole package.json to be inlined to the bundle, but it's also only referenced from the dev-only branch and that object is totally static, so it should be a prime candidate for production DCE

@codesandbox-ci
Copy link

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.

Latest deployment of this branch, based on commit a309c3c:

Sandbox Source
Emotion Configuration

Copy link
Member

@emmatown emmatown left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ughhh, I kinda feel like this warning wasn't the best idea but sure, this makes it slightly better.

@emmatown emmatown merged commit 58b2bbc into next Aug 21, 2020
@emmatown emmatown deleted the change-global-key branch August 21, 2020 20:43
@Andarist
Copy link
Member Author

Ughhh, I kinda feel like this warning wasn't the best idea but sure, this makes it slightly better.

Yeah, I have mixed feelings about it as well - the good thing though is that we can always drop it if we find to cause more harm than good.

louisgv pushed a commit to louisgv/emotion that referenced this pull request Sep 6, 2020
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

Successfully merging this pull request may close these issues.

None yet

2 participants