-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Description
Thanks for this lovely little lib! We are using it by default in Phoenix Liveview and we've had reports of Firefox layout reflows causing flickering. On page load occasionally CSS style are not applied on initial paint, which seems to be caused by a layout reflow triggered by nprogress. The second paint applies the styles. It also seems to be more pronounced with larger css files.
It has been traced down to this following lines:
https://github.com/rstacruz/nprogress/blob/master/nprogress.js#L74
https://github.com/rstacruz/nprogress/blob/master/nprogress.js#L89
When replaced with window.requestAnimationFrame()
the issue is reportedly fixed, but I have not tested locally.
If I can be of more help, let me know! It would be great to land with the work in #218 . Thanks!