Skip to content
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

Extract frontmatter parsing to metalsmith-matters plugin #169

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

Ajedi32
Copy link
Member

@Ajedi32 Ajedi32 commented Sep 16, 2015

Removes all code related to parsing frontmatter, and instead relies on the metalsmith plugin metalsmith-matters to provide that functionality.

This PR does not change the public API of metalsmith. That's something I plan on doing in later PRs. (See #157 for my thoughts on that.)

mockFiles[file] = ret;
frontmatter(mockFiles);
ret = mockFiles[file];
}
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Note that here I'm interacting with the plugin directly rather than running it via ware. I'm not 100% sure whether that was the right choice or not, but it seems clean enough.

@Ajedi32
Copy link
Member Author

Ajedi32 commented Sep 16, 2015

Also, it would be great if someone could look over my code over at https://github.com/Ajedi32/metalsmith-matters I've got pleany of experience with JavaScript, but this is my first time creating anything "real" for node.

@ianstormtaylor
Copy link
Contributor

Mentioned in the other thread, but I'm going to opt not to do this for now. For what it's worth, the diff does feel really nice being able to nix those lines :) if it wasn't for the public API, unshifting on the ware stack would have been cool in .run() to make it even simpler.

Anyways, thanks for the idea and interest and effort!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants