mirror of
https://github.com/withastro/astro.git
synced 2024-12-23 21:53:55 -05:00
* fix(#8625): smooth scrolling in SPA mode on iOS * perf(router): run cb every 200ms only when scolling * refactor(router): suggested changes and fixes Suggested changes: - change interval time from 200 to 50ms - initialize `last*` vars together with the call to `setInterval()` - clear interval when scroll positions stop changing, independent of history state Additional changes: - remove unused `throttle()` function - move guarded block to inside `onScrollEnd()` since using history navigation will trigger our "popstate" callback and fire additional "scroll" and "scrollend" events, causing redundant expensive calls to `replaceState()` * adds changeset --------- Co-authored-by: Martin Trapp <94928215+martrapp@users.noreply.github.com> |
||
---|---|---|
.. | ||
astro | ||
astro-prism | ||
astro-rss | ||
create-astro | ||
db | ||
integrations | ||
internal-helpers | ||
markdown/remark | ||
telemetry | ||
underscore-redirects | ||
upgrade |