framework7io / framework7io/framework7

[v2] Option for Infinite Scroll to Automatically Get List HTML From Pages

Open
#2,208 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Feature Request
Dominant language
JavaScript
Stars
18.8k
Forks
3.2k
PR merge metrics
No merged PRs in 30d

Description

This is a (multiple allowed):

  • bug
  • enhancement
  • feature-discussion (RFC)

I think it would be awesome for there to be a DRYer way to use infinite scroll. Currently, you have to transfer over your infinite scroll html to a javascript template string, which makes the code pretty WET if you use this frequently.

I'm not entirely sure how it would work, but I was thinking of having some sort of way to specify which list (id or class) needs to be scrolled infinitely when the page initializes. It would then cache the Template7 string with that id and convert it to a javascript template automatically. Might not be the best approach, but just a thought of how it might work.

Regardless, I think this would be great to have something like this to your code DRYer.

Contributor guide

Open the contributing guide

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 locating the existing infinite-scroll implementation and the code that currently consumes Template7 strings; the issue does not name specific files or tests. Clarify the intended initialization API, how a list id or class identifies the source HTML, and what caching and automatic conversion should mean. Done should include a documented, tested way to initialize infinite scroll without duplicating the list markup in a JavaScript template string.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
frontend, mobile
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Quiet
Clarity
Needs clarification
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.