Git Product home page Git Product logo

Comments (7)

jameheller98 avatar jameheller98 commented on August 19, 2024 2

Okay I have found problem, its terrible with my code and thank to issue #5525, I fix my code I had use
runOnJS(frameCb.setActive)(true)
in a worklet and that terrible, thank support to me @szydlovsky

from react-native-reanimated.

szydlovsky avatar szydlovsky commented on August 19, 2024 1

@jameheller98 there is no video 😄

from react-native-reanimated.

szydlovsky avatar szydlovsky commented on August 19, 2024 1

@jameheller98 alright, I can see there is some kind of error but I can't really go into detail and investigate without any reproduction. Please refer to how to make a minimal repro.

Your file fix unfortunately doesn't do the job - it breaks the logic of callbackId (stopping and activating callbacks doesn't work anymore because of wrong callbackId).

Other than that, I am also a bit puzzled that your fix contains changes to the code that weren't there yet as of 3.12 (they are present only on main branch and a few recent nightly builds).

from react-native-reanimated.

szydlovsky avatar szydlovsky commented on August 19, 2024

Hey @jameheller98 I have so many questions. Could you tell us what exactly is the problem? When i tried using your code that you provided, all of our examples using useFrameCallback stopped working as intended because of your callbackId logic. What exactly do you want us to do?

from react-native-reanimated.

szydlovsky avatar szydlovsky commented on August 19, 2024

Funfact: if you change autostart argument in the snack to true (or just remove it), it will work fine

from react-native-reanimated.

jameheller98 avatar jameheller98 commented on August 19, 2024

This here video example about error:

Uploading screen-20240624-204905~2.mp4…

I have found error when ref.current.callbackId not update in useEffect hook you can check.

from react-native-reanimated.

jameheller98 avatar jameheller98 commented on August 19, 2024

@szydlovsky

4623345153037303709.mp4

You can check again.

useFrameCallback.zip

And file fix you can check

from react-native-reanimated.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.