question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Using clockRunning/stop/start clock inside the proc

See original GitHub issue

I’ve been playing with proc and it looks so promising!

But I’ve noticed it doesn’t work with clockRunning, startClock, stopClock blocks, since we are passing animated param into each of them and all of this invariants throw.

If I commented those invariants, app crashes on execution. On Android it says something like that:

By the way, here are some perf results with my example. You can change these lines to use different versions. It renders 100 animated views, also animates 4 properties of each one with timing, so there are 400 timings. Check out perf monitor and delay until animation plays.

Without proc : useTiming

With some atomic proc usage (everything except clockRunning, startClock, stopClock):

useProcTiming

Everything wrapped with proc:

useSuperProcTiming

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Reactions:4
  • Comments:11 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
terrysahaidakcommented, Sep 28, 2019

@khorark You can pass the clock as an argument, however, currently, you cannot call stopClock, clockRunning, startClock inside the proc.

1reaction
ddzirtcommented, Sep 26, 2019

Ok

Read more comments on GitHub >

github_iconTop Results From Across the Web

No results found

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found