michaelbromley / michaelbromley/angularUtils

dirPagination 3.10.9: Setting a value to total-items to make the data load synchronous

Open
#443 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
JavaScript
Stars
2k
Forks
842
PR merge metrics
No merged PRs in 30d

Description

Description of issue:
Hello, in advance thanks for your great work.
I'm suggesting an enhancement that, imho, would benefit your project.

Would it be possible that 'total-items' attribute could have a default value like -1 that would make the pagination synchronous?

I'm saying this because I have two arrays of objects, one synchronous and the other asynchronous in the same dir-paginate and since the total-items assumes that the current pagination will be "async" it does not update the pagination-controls when I change to the "sync" array.

Best regards,

Diogo da Silva

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by tracing how the dir-paginate directive handles the total-items attribute and how pagination-controls reacts when the data source changes between asynchronous and synchronous arrays. Define the default-value behavior and verify that switching arrays updates the controls without requiring an explicit total-items value.

Written by the indexing model from the issue text.

Assessment

Tech stack
angularjs
Domain
frontend
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.