Giter VIP home page Giter VIP logo

simple-infinite-scroll's Introduction

Django Simple Infinite Scroll

Example used in the blog post How to Create Infinite Scroll With Django

Running Locally

git clone https://github.com/sibtc/simple-infinite-scroll.git
pip install -r requirements.txt
python manage.py migrate
python manage.py runserver

simple-infinite-scroll's People

Contributors

vitorfs avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

simple-infinite-scroll's Issues

Infinite scroll not working correctly in CBV

The pagination of articles are not working correctly.

The page seems not to be changing.

In the template, articles.html

  {% if page_obj.has_next %}
    <a class="infinite-more-link" href="?page={{ articles.next_page_number }}">More</a>
  {% endif %}

The correct is to take the page number from the page_obj.

Like this:

  {% if page_obj.has_next %}
    <a class="infinite-more-link" href="?page={{ page_obj.next_page_number }}">More</a>
  {% endif %}

Add tutorial link to repo

Hey, i saw the tutorial first and it was a nice one, and came here from the tutorial. But, if a person saw the repo first, there is no way to find the tutorial. Can you please add its link to repo details or README, so people can find it.

Thank you so much.

Issue with versions. Runtime error with new versions of Python.

I get this error when migrating or running server:
RuntimeError: class not set defining 'AbstractBaseUser' as <class 'django.contrib.auth.base_user.Abstract BaseUser'>. Was classcell propagated

I think the problem is with versions differences. Please test your code with new versions so there is no issue with new comers who use new versions of Python.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.