-
Notifications
You must be signed in to change notification settings - Fork 43
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix #21 and #28 #37
base: master
Are you sure you want to change the base?
Fix #21 and #28 #37
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Only use lodash.sortby rather than the whole package.
@@ -1,210 +1,143 @@ | |||
|
|||
var _ = require('lodash'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Rather than including the whole of lodash, it would be good to include the packages needed.
e.g.
var sortBy = require('lodash.sortby');
and amend line 87 to match the variable name.
}, | ||
"dependencies": { | ||
"slug": "^0.9.1" | ||
"lodash": "^4.15.0", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Don't forget to change the dependency too:
"lodash.sortby": "^4.7.0"
@mdotasia Can you rebase to resolve the conflicts? |
@mdotasia if you can rebase and resolve the conflicts, we'll get this PR merged in. |
This PR fixes #28 and presumably #21:
metalsmith-collections
.index.js
and used variable names that make reading and understanding the code easier.files
and verify anything I want to verify regarding the tag pages.tags
for pages has now the same structure as the globaltags
. This is to ensure that I can re-use a layout partial to display all tags or only page tags without having to modify how to accesstag
andurlSafe
. This might conflict with PR Add a tagsCollection object holding a display & url safe tag label #34.skipMetadata
option. It looked to me that it did not save much processing because the plugin still needs to create the globaltags
data structure.