Sadly, % is a special YAML character for registering tags, and that means that you have to put quotes around every single string that uses them in first position.
(person)=>: "%($person.first) %($person.last)"
This destroys one of the most useful features of YAML, which is that making strings is really easy. Instead, we should choose a template syntax that lets us drop the quotes. Here are a couple of suggestions.
(person)=>: << $person.first> << $person.last>
(person)=>: (= $person.first) (= $person.last)
(person)=>: (% $person.first) (% $person.last)
Sadly,
%is a special YAML character for registering tags, and that means that you have to put quotes around every single string that uses them in first position.This destroys one of the most useful features of YAML, which is that making strings is really easy. Instead, we should choose a template syntax that lets us drop the quotes. Here are a couple of suggestions.