Giter VIP home page Giter VIP logo

Comments (13)

hamelsmu avatar hamelsmu commented on May 18, 2024 1

@zonca this is great! Thanks for sharing! I'll get around to this soon

from fastpages.

mikonapoli avatar mikonapoli commented on May 18, 2024

Had a read to the docs linked, and wanted to have a stab at this after I finished with #49 but I cannot find where the post list is built in the index page. In other words: index.md contains only a bit of content, but when the site is actually built a list of posts is added. I think I am looking for the "home" layout, but I cannot find it

from fastpages.

mikonapoli avatar mikonapoli commented on May 18, 2024

I have tried for a bit, but the answer is that apparently it is not possible, or not in an easy way. There are two main issues:

  1. Although this minima layout has been pushed to master, for some reason it's not being picked up (we might be using a different theme or a different version, I don't know). This is not a major deal, and it can be solved with a custom layout, although it is a bit hacky

  2. The paginator requires the index to be index.html rather than index.md (I am guessing so that it can duplicate it several time depending on how many pages are needed. This does not seem easily solvable to me unless we are willing to break the basic assumptions of fastpage.

from fastpages.

hamelsmu avatar hamelsmu commented on May 18, 2024

Indeed looks like pagination is built in to the currenty version of minima, however, they haven't cut a release yet so its not available for people installing via Gem.

I'm not adventurous enough to copy their files etc. Perhaps we look at the upcoming 3.0 release and see what has changed ( or actually wait until 3.1 )

from fastpages.

mikonapoli avatar mikonapoli commented on May 18, 2024

Perhaps. Should we label this issue as "waiting" or something?

from fastpages.

hamelsmu avatar hamelsmu commented on May 18, 2024

I’ll keep it open for a bit :)

from fastpages.

zonca avatar zonca commented on May 18, 2024

I made pagination working following jekyll/minima#150 (comment)

  1. Added gem 'jekyll-paginate' to Gemfile

  2. added to _config.yml:

gems:
  - jekyll-paginate

paginate: 10
paginate_path: /page:num/
  1. I had an empty index.md so just renamed it, I guess people with some content should turn it into html.

     mv index.md index.html
    

See at: https://zonca.dev/

from fastpages.

hamelsmu avatar hamelsmu commented on May 18, 2024

One issue with using the paginate plugin is that you have to convert index.md to index.html, and it becomes much harder to write content this way. Any ideas on how to make things easier to let people write content on their home page?

from fastpages.

zonca avatar zonca commented on May 18, 2024

@hamelsmu What if in the build action fastpages adds a script which converts index.md to index.html before it is processed by Jekyll?

from fastpages.

hamelsmu avatar hamelsmu commented on May 18, 2024

No that wouldn't work in this case. And there isn't a way to ship markdown inside HTML, either. the best way is to try to find a way to port pagination to markdown via {% includes %} or something like that or by extending _layout/home.html

from fastpages.

zonca avatar zonca commented on May 18, 2024

what if you strip the front matter, do the conversion using pandoc or some other tool, and join back the front matter?

from fastpages.

hamelsmu avatar hamelsmu commented on May 18, 2024

@zonca don't want to hack it like that seems like it would not be very maintainable.

I'm thinking to just put a link to your instructions in the documentation instead?

from fastpages.

zonca avatar zonca commented on May 18, 2024

Sure

from fastpages.

Related Issues (20)

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.