Git Product home page Git Product logo

Comments (6)

jonschlinkert avatar jonschlinkert commented on August 15, 2024

hey @andismith, sorry you had to deal with this, especially when there was a fix waiting for me to push up. I just pushed up an update for the withSort helper, as well as additional documentation:

All of the credit for these goes to @Arkkimaagi, who has been patiently waiting for me to catch up. Please let me know if this works for you, and definitely reopen this if it doesn't!

from handlebars-helpers.

jonschlinkert avatar jonschlinkert commented on August 15, 2024

oh, btw, I'm going to publish a new version of this repo to npm in the next 3 min...

from handlebars-helpers.

andismith avatar andismith commented on August 15, 2024

That's cool this has the ability to sort on an object's properties, thank you. How would I go about reverse sorting (desc)? For example, I want to sort on year descending (2013, 2012, 2011).

Thanks.

Btw, sorting on an object's properties seems to be working for me in some instances - but I'm still having a couple of issues - I'm still trying to figure out whether this is something I've done or not, so won't report it until I know.

from handlebars-helpers.

andismith avatar andismith commented on August 15, 2024

Hi, has there been any progress with being able to use withSort to sort backwards? I'm thinking dates in reverse order.

from handlebars-helpers.

andismith avatar andismith commented on August 15, 2024

Nevermind, I just figured I can sort a collection. This did it:

collections: [{
name: 'post',
sortby: 'posted',
sortorder: 'descending'
}

from handlebars-helpers.

jonschlinkert avatar jonschlinkert commented on August 15, 2024

Awesome, I was just about to comment...

fwiw, @doowb and I are going to be making some big updates and improvements to virtually everything about assemble really soon. Including a full refactor and a big upgrade to the docs. and issues like this will hopefully resolved faster.

from handlebars-helpers.

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.