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

Performance Issue on Safari (Mobile & Web) #1085

Open
zurez opened this issue Jul 16, 2020 · 8 comments
Open

Performance Issue on Safari (Mobile & Web) #1085

zurez opened this issue Jul 16, 2020 · 8 comments
Labels
area: performance issues with performance in particular targets type: help wanted Extra attention is needed

Comments

@zurez
Copy link

zurez commented Jul 16, 2020

🐛 Bug Report

The following example is very laggy while running on safari , though it is very smooth on Chrome Android

To Reproduce

https://codesandbox.io/embed/j0y0vpz59
Steps to reproduce the behavior:
View the above url on iOS

@zurez zurez changed the title Performance Issue on Safar (Mobile & Web) Performance Issue on Safari (Mobile & Web) Jul 16, 2020
@aleclarson aleclarson added the area: performance issues with performance in particular targets label Jul 16, 2020
@kldnajjar
Copy link

kldnajjar commented Nov 20, 2020

I have the same issue, the performance into chrome is perfect but thats not the case with Safari its lagging, when the parent state is too large more and more lagging it would be

@art-smi

This comment has been minimized.

@joshuaellis joshuaellis added the type: help wanted Extra attention is needed label Mar 18, 2021
@xzilja
Copy link

xzilja commented Apr 15, 2021

Same issue in non dom renderers like https://reactpixi.org and https://github.com/konvajs/react-konva, using "@react-spring/core": "9.1.1" to get useSpring

Not sure if it's helpful, but using https://greensock.com/gsap on same renderers doesn't seem to cause performance issues.

@joshuaellis
Copy link
Member

Same issue in non dom renderers like https://reactpixi.org and https://github.com/konvajs/react-konva, using "@react-spring/core": "9.1.1" to get useSpring

Not sure if it's helpful, but using https://greensock.com/gsap on same renderers doesn't seem to cause performance issues.

If you can provide an example repro that'd be great. I've never used Konva before

@CodyJasonBennett
Copy link
Member

Looking at the attached sandbox, this SO question might be related.

Unfortunately, I can't recreate this issue without a physical Apple device to investigate.

@joshuaellis joshuaellis added this to the v9.X.X milestone May 13, 2021
@Obi-Dann
Copy link

Got the same issue with react-konva on both Mac and Windows when upgrading from v8 to v9. Not sure if the issue with react-konva is related to the originally reported issue. The performance degradation seems to start with version 9.
Codesandbox with a simple react-konva animation using version 8, very smooth:
https://codesandbox.io/s/react-springkonva-performance-issue-v8-d4q8l

Codesandbox with a simple react-konva animation using version 9, performance is noticeably worse:
https://codesandbox.io/s/react-springkonva-performance-issue-v9-v0b9u

@alexkrkn
Copy link

alexkrkn commented May 8, 2023

Looking at the attached sandbox, this SO question might be related.

Unfortunately, I can't recreate this issue without a physical Apple device to investigate.

The linked stackoverflow answer resolved the issue for me.
It happened with both desktop and mobile Safari with the latest [email protected]. Adding transform: translate3d(0%,0,0); to the animated element made it a smooth animation like on chrome.

@sidpremkumar
Copy link

Looking at the attached sandbox, this SO question might be related.
Unfortunately, I can't recreate this issue without a physical Apple device to investigate.

The linked stackoverflow answer resolved the issue for me. It happened with both desktop and mobile Safari with the latest [email protected]. Adding transform: translate3d(0%,0,0); to the animated element made it a smooth animation like on chrome.

Nice yeah can confirm this still works and solved my problem as well.

Just went from

    <animated.div 
      style={{
        ...fade,
      }}
    >
      {children}
    </animated.div>

to

    <animated.div
      style={{
        transform: "translate3d(0, 0, 0)", // Just added this
        ...fade,
      }}
    >
      {children}
    </animated.div>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: performance issues with performance in particular targets type: help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

10 participants