{"action":"closed","issue":{"url":"https://api.github.com/repos/jekyll/jekyll/issues/3410","labels_url":"https://api.github.com/repos/jekyll/jekyll/issues/3410/labels{/name}","comments_url":"https://api.github.com/repos/jekyll/jekyll/issues/3410/comments","events_url":"https://api.github.com/repos/jekyll/jekyll/issues/3410/events","html_url":"https://github.com/jekyll/jekyll/issues/3410","id":56554873,"number":3410,"title":"Interpolation in YAML frontmatter","user":{"login":"nybblr","id":794113,"avatar_url":"https://avatars.githubusercontent.com/u/794113?v=3","gravatar_id":"","url":"https://api.github.com/users/nybblr","html_url":"https://github.com/nybblr","followers_url":"https://api.github.com/users/nybblr/followers","following_url":"https://api.github.com/users/nybblr/following{/other_user}","gists_url":"https://api.github.com/users/nybblr/gists{/gist_id}","starred_url":"https://api.github.com/users/nybblr/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nybblr/subscriptions","organizations_url":"https://api.github.com/users/nybblr/orgs","repos_url":"https://api.github.com/users/nybblr/repos","events_url":"https://api.github.com/users/nybblr/events{/privacy}","received_events_url":"https://api.github.com/users/nybblr/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":8,"created_at":"2015-02-04T16:58:54Z","updated_at":"2015-12-13T20:48:07Z","closed_at":"2015-12-13T20:48:07Z","body":"I'm working on a Jekyll app that hosts a blog, various pages, and a ton of bios. All of these pages share the exact same layout. The bios have frontmatter like `name` and `position` all specified.\r\n\r\nAll the bios (quite a few them) need to have a particular `title` format: `\"#{page.name} - #{page.position}\"`. However, the only way I can accomplish this without duplicating my main layout (along with the various _includes) is to manually build the `title` attribute out for every single bio entry (on the order of 100 entries). Neither solution feels DRY.\r\n\r\nI've entertained a few different ways this could be accomplished:\r\n\r\n1. **A `yield` mechanism** such as ERB allows. This seems like it might be tricky to implement though and might run against the grain of Liquid?\r\n2. **Allow a page to specify (in its frontmatter) what Page type it should be hydrated with.** Then I could just specify `page_type: BioPage` and implement a page type that defines a `title` method. This mechanism would also allow a default page type to be specified in `_config`. It seems like a potentially elegant solution that could make similar problems easier.\r\n3. **Allow interpolation in the Yaml frontmatter,** similar to Rails' interpolation syntax in locales. Thus, I could simply have all the bios use an intermediary layout called `bio`, and the `bio` layout would use the `default` layout, but with one YAML frontmatter addition: `title: \"%{name} - %{position}\"`\r\n\r\nThose last 2 options seem like good feature additions to Jekyll, but is there a similar mechanism already in place that would make them less desirable (or would solve the duplication issue I currently face)?"}}