Skip to content

Better template syntax #34

@cowboyd

Description

@cowboyd

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)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions