add sort option#54
Conversation
|
Hi @Daley, thanks for your pull request! There is another one before your PR, can you explain the differences between that one and this one? |
| "name": "serve-index", | ||
| "description": "Serve directory listings", | ||
| "version": "1.7.3", | ||
| "version": "1.7.4", |
There was a problem hiding this comment.
Please undo this version bump.
|
#41 seems to sort by a function that is passed. This one just adds the sort by modified date. This one is simpler and the other is more versatile. It's up to you, but I think this function is very much needed |
|
Will this be merged ? |
|
It'd be awesome if you could merge in one of the two sort solutions. :) |
|
I at least need the PR updated with the change request I made. Since I requested the change a year ago and the PR still hasn't been updated, I'm just going to close it. Someone can always open a new PR if they are interested in picking it up and making any changes from review feedback. |
|
Ah ok, bummer @mrv777 didn't make that correction for you. Since I only needed sorting myself for a specific one-off project, I just manually changed fileSort to the code he used. |
app.use('/', serveIndex("dir", {'icons': true,sort:serveIndex.fileSortWithMTime}));