4 ms·
Jekyll Data Files
- pault 13y agoAlso works in middleman if you don't need a blog baked in: http://middlemanapp.com/advanced/local-data/ http://middlemanapp.com/advanced/local-data/
- straws 13y agoBut also if you do: https://github.com/middleman/middleman-blog https://github.com/middleman/middleman-blog
- avolcano 13y agoNot sure why OP linked to the Github file instead of the file on the site (w/ syntax highlighting, etc.): http://jekyllrb.com/docs/datafiles/ http://jekyllrb.com/docs/datafiles/ It's also worth noting that you could already do this in _config.yml, this just lets you split that up.
- philip1209 13y agoThis is great. I've found myself frustrated by the Liquid templating system, though. For instance, the print was inserting a line break that was messing with meta tags on my website.
- straws 13y agoCould you speak more about the things you dislike in Liquid? It's one of my favorite templating systems, especially if you're treating it in the same way as you would mustache templates, i.e., using a view-model or decorator to prep data from a model. If you're using a lot of `assign` or `capture` tags, it's horrible.
- philip1209 13y agoSpecifically, the error I couldn't figure out how to remedy was the line break caused by the included statement that was in this commit: https://github.com/philipithomas/www.philipithomas.com/commit/62c76ce7eaf23fff3049934012a027976fb92d81 https://github.com/philipithomas/www.philipithomas.com/commi...
- homosaur 13y agoI wonder if the reason you were having trouble with Liquid is that you were using it incorrectly. It's definitely meant to be secure over simple. Was the issue you were having a bug or did you find a way to fix the encoding?
- philip1209 13y agoSee the below comment, but it was the "include" here causing a line break that I couldn't figure out: https://github.com/philipithomas/www.philipithomas.com/commit/62c76ce7eaf23fff3049934012a027976fb92d81 https://github.com/philipithomas/www.philipithomas.com/commi...
- swanson 13y agoHi - I wrote the docs for this. It is a really awesome feature, but be aware that it is targeted at Jekyll 1.3 - which is not quite released yet (https://github.com/mojombo/jekyll/issues?milestone=14&state=open https://github.com/mojombo/jekyll/issues?milestone=14&state=...), nor deployed to GitHub Pages yet :) You can check here: https://github.com/github/pages-gem/blob/master/github-pages.gemspec https://github.com/github/pages-gem/blob/master/github-pages... to find out when Pages will be updated to 1.3.X
- kevinSuttle 13y agoMixture handles this in a slightly more elegant and flexible way via models and collections. http://mixture.io http://mixture.io https://github.com/teammixture/mixture-collections https://github.com/teammixture/mixture-collections As mentioned, Middleman can use JSON or YML. http://middlemanapp.com/advanced/local-data/ http://middlemanapp.com/advanced/local-data/