This repository was archived by the owner on Mar 4, 2020. It is now read-only.
chore(Animation): move to function component, styles in theme are not required#2258
Merged
layershifter merged 8 commits intomasterfrom Feb 12, 2020
Merged
chore(Animation): move to function component, styles in theme are not required#2258layershifter merged 8 commits intomasterfrom
layershifter merged 8 commits intomasterfrom
Conversation
Contributor
|
@layershifter is this related to #2247? |
Member
Author
|
@jurokapsiar Yes, it will fix it 👍 |
0c8cd09 to
af2af43
Compare
layershifter
commented
Feb 10, 2020
| disableAnimations: context.disableAnimations, | ||
| renderer: context.renderer, | ||
| rtl: context.rtl, | ||
| saveDebug: _.noop, |
Member
Author
There was a problem hiding this comment.
Should we have debug for Animation component?
Collaborator
Perf comparison
Potential regressions comparing to master
Perf tests with no regressions
Generated by 🚫 dangerJS |
mnajdova
reviewed
Feb 12, 2020
| (React.Children.only(children) as React.ReactElement) | ||
|
|
||
| const element = ( | ||
| <> |
mnajdova
reviewed
Feb 12, 2020
| rtl: context.rtl, | ||
| saveDebug: _.noop, | ||
| theme: context.theme, | ||
| _internal_resolvedComponentVariables: context._internal_resolvedComponentVariables, |
Contributor
There was a problem hiding this comment.
This is removed. Please update your branch
mnajdova
reviewed
Feb 12, 2020
| }) | ||
| }, [ | ||
| className, | ||
| context, |
Contributor
There was a problem hiding this comment.
Are we using everything from the context? Should we maybe list the things used from the context
Member
Author
There was a problem hiding this comment.
disableAnimations: context.disableAnimations,
renderer: context.renderer,
rtl: context.rtl,
theme: context.theme,
Almost everything... So I don't see any benefits in destructing it...
…ithub.com/stardust-ui/react into chore/move-animation-to-fc � Conflicts: � CHANGELOG.md
mnajdova
approved these changes
Feb 12, 2020
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
BREAKING CHANGES
Utility styles from the
Animationcomponent where moved to the component itself. No upgrade path there as there should no be any custom styles forAnimationcomponent as custom animations are defined in the theme.Fixes #2247.
Also affect affects performance improvements as styles now be recomputed only on demand.