avillafiorita / jekyll-datapage_gen

Generate one page per yaml record in Jekyll sites.
369 stars 80 forks source link

Add name expr #63

Closed DanielJDufour closed 4 years ago

DanielJDufour commented 4 years ago

Thank you so much for this awesome plugin!

This Pull Request adds a name_expr option to your config, so people can programmatically generate filenames based on a Ruby expression. We are using this with http://geography2050.org, so we can create filenames based on the combination of both the first_name and last_name fields in a CSV.

I also added in some code so that if the data includes a name key, people can still access that key-value through page._name in a layout.

avillafiorita commented 4 years ago

thanks!