Multiple pages with metadata from a folder of markdown files
rasta a folder of markdown files with yaml headers and you'll get back markdown with some metadata.
(Originally, I intended to make this module generate a team roster and individual bio pages. Hence the name.)
npm install rasta
Just include a simple section of yaml at the header of each bio, fenced in with three dashes above and three dots below.
Whatever associated content you'd like associated with that metadata goes below that.
---name: Andrew Ryantitle: Chief Bio Officerslug: andyimage: /images/andy.png...Here's my cool content!
var Rasta = require('rasta');var rasta = new Rasta(__dirname + '/team');var allTheThings = rasta.all();console.log(allTheThings);var justOneOfTheThings = rasta.getBySlug('some-url-slug');console.log(justOneOfTheThings);
Then check out the example!
And that's it! Now you're cooking with rasta!
(I don't think that's a thing though.)