Skip to content

Angular 14 scroll not triggering #458

Open
@benalex94

Description

@benalex94

Hey,

I have a page of dynamic elements for accommodation locations and was looking to create a quick links list to scroll through them. I have tried everything but can't seem to get it to scroll at all.

The page is accommodation and the href is a unique string linked to an id #scroll-1 2 3 ... etc

I have been testing on chrome and saw the issue relating to smooth scroll that has no effect on my app

Currently clicking a link seems to do nothing

<h3>Quick Links</h3>
       <ol class="accommodation-links">
             <li *ngFor="let room of allAccommodation; let i = index">
                    <a pageScroll routerLink="/accommodation" [href]="'#scroll-'+i" [title]="'View '+room.name">{{room.name}</a>
            </li>
       </ol>

Working page
localhost_accommodation

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions