Key changes
CSS SVG Animations
CSS animations now support animating SVG components and their properties, including Path, Image, LinearGradient, RadialGradient, Pattern and Text. This includes support for animating the d property of Path components with a special handling for path morphing.
- feat: Implement CSS SVG Polyline by @wisniewskij in https://github.com/software-mansion/react-native-reanimated/pull/9003
- feat: Implement CSS SVG Polygon by @MatiPl01 in https://github.com/software-mansion/react-native-reanimated/pull/9008
- feat: Support
%length values in SVG CSS animations by @MatiPl01 in https://github.com/software-mansion/react-native-reanimated/pull/9011 - Add css SVG Path parser and normalizer by @wisniewskij in https://github.com/software-mansion/react-native-reanimated/pull/8709
- CSS SVGPath interpolation by @wisniewskij in https://github.com/software-mansion/react-native-reanimated/pull/8710
- Enable support for SVGImage in CSS by @wisniewskij in https://github.com/software-mansion/react-native-reanimated/pull/8830
- feat: Add support for SVG
Patterncomponent in SVG animations by @MatiPl01 in https://github.com/software-mansion/react-native-reanimated/pull/9041 - CSS SVGRadialGradient support by @wisniewskij in https://github.com/software-mansion/react-native-reanimated/pull/8871
- CSS SVGLinearGradient support by @wisniewskij in https://github.com/software-mansion/react-native-reanimated/pull/8917
- Enable support for SVGText in CSS by @wisniewskij in https://github.com/software-mansion/react-native-reanimated/pull/9022
Shared Value re-implementation
Shared Value internal implementation changed - now it uses Shareable type from react-native-worklets as its internal value container. That means you can finally use Shared Values from other Worklet Runtimes than just the UI Runtime. Also USE_SYNCHRONIZABLE_IN_MUTABLE optimization feature flag is now enabled by default.
- feat(Reanimated): enable Synchronizable in Mutable by default by @tjzel in https://github.com/software-mansion/react-native-reanimated/pull/9068
- feat(Reanimated): use Shareable for Mutables by @tjzel in https://github.com/software-mansion/react-native-reanimated/pull/9004
Animated Styles type changes
TypeScript type of Animated Styles now makes it impossible to accidentally pass them to non-animated components. This replaces previous runtime-check for this kind of mistake, which proved to be prone to false positives.
- refactor: make AnimatedStyle type fail on non-animated components by @tjzel in https://github.com/software-mansion/react-native-reanimated/pull/8990
Fixes
- fix: use native processTransformOrigin instead of web version by @maxpotemkin in https://github.com/software-mansion/react-native-reanimated/pull/8738
- fix: prefab headers locations by @tjzel in https://github.com/software-mansion/react-native-reanimated/pull/8747
- fix: Proper support for nested
animatedPropsobjects and correct cleanup by @MatiPl01 in https://github.com/software-mansion/react-native-reanimated/pull/8726 - fix(web): Support originX and originY in layout animations by @choi138 in https://github.com/software-mansion/react-native-reanimated/pull/8733
- fix: Web entering animations triggered on view exiting by @MatiPl01 in https://github.com/software-mansion/react-native-reanimated/pull/8772
- fix: Animation names array order updates on keyframes order change by @MatiPl01 in https://github.com/software-mansion/react-native-reanimated/pull/8777
- fix:
Infinityparsing in web CSSanimationIterationCountby @MatiPl01 in https://github.com/software-mansion/react-native-reanimated/pull/8787 - fix: FORCE\_REACT\_RENDER\_FOR\_SETTLED\_ANIMATIONS feature flag crashes by @MatiPl01 in https://github.com/software-mansion/react-native-reanimated/pull/8822
- fix:
SharedValue.modifystrict type definition by @huextrat in https://github.com/software-mansion/react-native-reanimated/pull/8846 - fix: FORCE\_REACT\_RENDER\_FOR\_SETTLED\_ANIMATIONS incorrect color alphas by @DouweBos in https://github.com/software-mansion/react-native-reanimated/pull/8841
- fix: Guard for undefined style in Jest utils by @msynowski in https://github.com/software-mansion/react-native-reanimated/pull/8878
- fix: Stop passing nativeID to component in jest unit tests by @MatiPl01 in https://github.com/software-mansion/react-native-reanimated/pull/8881
- Fix the issue with next.js throwing errors while hydrating by @5ZYSZ3K in https://github.com/software-mansion/react-native-reanimated/pull/8869
- fix:
useHandlernot working on web without babel plugin by @MatiPl01 in https://github.com/software-mansion/react-native-reanimated/pull/8883 - fix:
nopluginoption being ignored in the web-example by @MatiPl01 in https://github.com/software-mansion/react-native-reanimated/pull/8933 - fix: CSS SVGPath android parsing bugfix by @wisniewskij in https://github.com/software-mansion/react-native-reanimated/pull/8918
- fix: free \_\_cxa\_demangle allocations in SingleInstanceChecker by @jingjing2222 in https://github.com/software-mansion/react-native-reanimated/pull/8964
- fix: pass shouldPersistRemote to cloneObjectProperties by @aljadan in https://github.com/software-mansion/react-native-reanimated/pull/8995
- fix: Fix native
matchVersionnot allowing patch version mismatches by @kitten in https://github.com/software-mansion/react-native-reanimated/pull/9018 - fix: CSS transitions not working when a prop is added or removed by @MatiPl01 in https://github.com/software-mansion/react-native-reanimated/pull/9014
- fix: static frameworks missing header paths by @tjzel in https://github.com/software-mansion/react-native-reanimated/pull/9035
- Fix sync props back to React mechanism by @tomekzaw in https://github.com/software-mansion/react-native-reanimated/pull/9046
- Fix: Add missing initialization in SVG Path by @wisniewskij in https://github.com/software-mansion/react-native-reanimated/pull/9058
- fix: RN 0.81 TS errors by @tjzel in https://github.com/software-mansion/react-native-reanimated/pull/9059
- fix: CSS animation box-shadow crashes by @MatiPl01 in https://github.com/software-mansion/react-native-reanimated/pull/9065
- fix: CSS transition flickering on
transitionPropertychange by @MatiPl01 in https://github.com/software-mansion/react-native-reanimated/pull/9120 - fix: guard against null styleProps in PropsRegistry GC by @mobinni in https://github.com/software-mansion/react-native-reanimated/pull/9052
- fix - passing negative values to
filtercrashes on iOS by @intergalacticspacehighway in https://github.com/software-mansion/react-native-reanimated/pull/9155 - \[Android] Fix commits during drawing by @bartlomiejbloniarz in https://github.com/software-mansion/react-native-reanimated/pull/9072
- perf: Don't trigger CSS transition for props with effective duration 0 by @MatiPl01 in https://github.com/software-mansion/react-native-reanimated/pull/9118
- chore:
useHandlerreimplementation by @MatiPl01 in https://github.com/software-mansion/react-native-reanimated/pull/9090
react-native-reanimated/pull/9015
Refactors
- refactor(Reanimated): use own SingleInstanceChecker by @tjzel in https://github.com/software-mansion/react-native-reanimated/pull/8935
- refactor: move events to Reanimated by @tjzel in https://github.com/software-mansion/react-native-reanimated/pull/8934
- refactor(Reanimated): use own JSIUtils by @tjzel in https://github.com/software-mansion/react-native-reanimated/pull/8938
- refactor: Rename processOpacity to processPercentage by @wisniewskij in https://github.com/software-mansion/react-native-reanimated/pull/8947
- Extract
applySynchronousUpdatesfromperformOperationsby @bartlomiejbloniarz in https://github.com/software-mansion/react-native-reanimated/pull/9078 - Replace
isIntwithisNumberin synchronous props check by @tomekzaw in https://github.com/software-mansion/react-native-reanimated/pull/9113
Chores
- Add
_beginSectionand_endSectionJSI bindings for systraces by @tomekzaw in https://github.com/software-mansion/react-native-reanimated/pull/9101 - Add
_startProfilingand_stopProfilingJSI bindings for Hermes sampling profiler by @tomekzaw in https://github.com/software-mansion/react-native-reanimated/pull/9102 - feat: Common fallback style props builder for any unsupported component by @MatiPl01 in https://github.com/software-mansion/react-native-reanimated/pull/8989
- feat: peer dependencies validation by @tjzel in https://github.com/software-mansion/react-native-reanimated/pull/9019
- feat: stable API versioning checks by @tjzel in https://github.com/software-mansion/react-native-reanimated/pull/9105
- chore: modernize build.gradle scripts by @tjzel in https://github.com/software-mansion/react-native-reanimated/pull/8707
- chore: consider new arch always enabled in react-native 0.82+ by @gabrieldonadel in https://github.com/software-mansion/react-native-reanimated/pull/8771
- chore: Change props overriding behavior in the props builder by @MatiPl01 in https://github.com/software-mansion/react-native-reanimated/pull/8877
- chore: Change
folly::dynamictojsi::ValueinupdateKeyframesfor CSS transitions by @MatiPl01 in https://github.com/software-mansion/react-native-reanimated/pull/8982 - chore: bump gradle versions by @tjzel in https://github.com/software-mansion/react-native-reanimated/pull/8994
- chore: only consider latest patch in compatibility tables by @tjzel in https://github.com/software-mansion/react-native-reanimated/pull/9142
- chore: unpin dependencies by @tjzel in https://github.com/software-mansion/react-native-reanimated/pull/9143
- chore(Rea): migrate to RCTModernEventEmitter by @tjzel in https://github.com/software-mansion/react-native-reanimated/pull/9033
- chore: Remove unused
hasPropfunction, improvetransformOriginprocessor types by @MatiPl01 in https://github.com/software-mansion/react-native-reanimated/pull/9173 - Enable
USE_COMMIT_HOOK_ONLY_FOR_REACT_COMMITSfeature flag by default by @tomekzaw in https://github.com/software-mansion/react-native-reanimated/pull/8716 - Remove workaround for dynamic frameworks by @tomekzaw in https://github.com/software-mansion/react-native-reanimated/pull/8927
- Remove deprecated
react-test-renderertype from published declarations by @YevheniiKotyrlo in https://github.com/software-mansion/react-native-reanimated/pull/9055 - Reorder examples imports by @tomekzaw in https://github.com/software-mansion/react-native-reanimated/pull/9112
- Bump minimal React Native version to 0.81 by @tomekzaw in https://github.com/software-mansion/react-native-reanimated/pull/9109
- Remove unnecessary
react_native_assertforsurfaceIdby @tomekzaw in https://github.com/software-mansion/react-native-reanimated/pull/9158 - Remove dead code in build.gradle by @tomekzaw in https://github.com/software-mansion/react-native-reanimated/pull/9177
New Contributors
- @maxpotemkin made their first contribution in https://github.com/software-mansion/react-native-reanimated/pull/8738
- @kimchi-developer made their first contribution in https://github.com/software-mansion/react-native-reanimated/pull/8754
- @choi138 made their first contribution in https://github.com/software-mansion/react-native-reanimated/pull/8733
- @p-malecki made their first contribution in https://github.com/software-mansion/react-native-reanimated/pull/8793
- @roitium made their first contribution in https://github.com/software-mansion/react-native-reanimated/pull/8821
- @patrickmichalik made their first contribution in https://github.com/software-mansion/react-native-reanimated/pull/8794
- @radoslawrolka made their first contribution in https://github.com/software-mansion/react-native-reanimated/pull/8831
- @huextrat made their first contribution in https://github.com/software-mansion/react-native-reanimated/pull/8846
- @DouweBos made their first contribution in https://github.com/software-mansion/react-native-reanimated/pull/8841
- @msynowski made their first contribution in https://github.com/software-mansion/react-native-reanimated/pull/8878
- @5ZYSZ3K made their first contribution in https://github.com/software-mansion/react-native-reanimated/pull/8869
- @riteshshukla04 made their first contribution in https://github.com/software-mansion/react-native-reanimated/pull/8901
- @OrfeasZ made their first contribution in https://github.com/software-mansion/react-native-reanimated/pull/8910
- @CDFN made their first contribution in https://github.com/software-mansion/react-native-reanimated/pull/8976
- @AlexRixten made their first contribution in https://github.com/software-mansion/react-native-reanimated/pull/8978
- @jingjing2222 made their first contribution in https://github.com/software-mansion/react-native-reanimated/pull/8964
- @aljadan made their first contribution in https://github.com/software-mansion/react-native-reanimated/pull/8995
- @kitten made their first contribution in https://github.com/software-mansion/react-native-reanimated/pull/9018
- @YevheniiKotyrlo made their first contribution in https://github.com/software-mansion/react-native-reanimated/pull/9055
- @tshmieldev made their first contribution in https://github.com/software-mansion/react-native-reanimated/pull/9130
- @avibega23 made their first contribution in https://github.com/software-mansion/react-native-reanimated/pull/9153
- @mobinni made their first contribution in https://github.com/software-mansion/react-native-reanimated/pull/9052
- @pkfms made their first contribution in https://github.com/software-mansion/react-native-reanimated/pull/9154
- @GrzywN made their first contribution in https://github.com/software-mansion/react-native-reanimated/pull/9175
Full Changelog: https://github.com/software-mansion/react-native-reanimated/compare/4.2.0...4.3.0