akveo / akveo/ng2-smart-table

Prevent page jump when refreshing table data

Open
#1,296 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
TypeScript
Stars
1.6k
Forks
867
PR merge metrics
No merged PRs in 30d

Description

I'm automatically refreshing the data by subscribing to HttpClient and populating LocalDataSource. Upon refresh, the page jump to top and back to the bottom where the table lies. I believe this is due to the table removing the rows then adding back the rows.

Any ideas how to prevent the page jump and make it data refresh more seamless?

source: LocalDataSource = new LocalDataSource();

this.httpService.getTableData()
.subscribe((data: Data[]) => {
this.source.load(data);
});

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.