Skip to content

Main-Nav, and other associated components, doesn't scroll properly on mobile. #101

@ghost

Description

When scrolling down the page, the main-nav component slowly eases to the top of the screen on desktop browsers, as well in mobile emulation. But, on an actual mobile device, the main-nav jumps around erratically.

On desktop, window.addEventListener('scroll', function() {}) is called continuously for every pixel scrolled, but mobile devices don't run the listener until the user has actually stopped scrolling completely. The only two ways around this that I've found:

  1. Get rid of the scrolling function, and just make the header and main-nav fixed.
  2. Use animations to mimic scrolling

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions