-
Notifications
You must be signed in to change notification settings - Fork 3
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 v10] Finish upgrading all things to emotion 10 #51
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good! Just a question on use of css
from a stylesheet
@@ -82,7 +83,7 @@ class Alert extends React.Component { | |||
> | |||
<AlertContentContainer> | |||
<Icon | |||
css={[alertIconStyles]} | |||
css={css`${alertIconStyles};`} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you clarify something? alertIconStyles
is created in style.js using css
. Is there a difference between creating it with css
vs wrapping in css
here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
oh nope, there's not. Both ways here are valid. https://emotion.sh/docs/composition
I just did a global search on css=
and updated all of it to use the template literal.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
${selectorIcon}; | ||
color: ${checked ? COLORS.white : 'transparent'}; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🙌 Good refactor on ordering
This PR adds the following to fully convert to emotion 10
babel-preset-css-prop
babel-plugin-emotion
css
prop to not use string and align with new usage from emotion 10.jest-emotion
config in serializer.