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

Add warning when passing incorrect transformOrigin #6602

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

Latropos
Copy link
Contributor

@Latropos Latropos commented Oct 16, 2024

Summary

Some view props, like colors are processed on JS level, so we process it in updateProps function:

However we don't implement our copy of processTransformOrigin and passing transformOrigin in a form of string crashes the app with a confusing error "Exception in HostFunction: , js engine: reanimated"

Yet, if transformOrigin is provided as an array of 3 numbers (just as you would get after calling processTransformOrigin on it) everything works fine, so I've added a warning explaining the problem.

Note

Similarly a fontVariant in form of string passed in useAnimatedStyle will not work. However this is not going to crash the whole app, so we probably want to ignore it. Also fontVariant accepts quantified values, so it doesn't make as much sense to animate it.

Test plan

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.

1 participant