Skip to content

Conformance Examples 0.1.0 — Render: identifier-formats

uri-fragment-simple

A URI fragment identifier (#/name) resolves the same as the equivalent RFC 6901 pointer (/name).

Template

{{ #/name }}

Context

{
    "name": "Alice"
}

Output

Alice

uri-fragment-nested

A URI fragment identifier navigates nested objects the same as RFC 6901.

Template

{{ #/user/city }}

Context

{
    "user": {
        "city": "Springfield"
    }
}

Output

Springfield

uri-fragment-percent-encoded

Percent-encoding in a URI fragment is decoded before pointer resolution; %20 becomes a space, addressing a key whose name contains a space.

Template

{{ #/first%20name }}

Context

{
    "first name": "Alice"
}

Output

Alice

dot-notation-simple

A bare word identifier (Mustache/Handlebars dot notation) resolves the top-level key of that name.

Template

{{ name }}

Context

{
    "name": "Alice"
}

Output

Alice

dot-notation-nested

Dot-separated segments navigate nested objects; 'user.city' resolves context['user']['city'].

Template

{{ user.city }}

Context

{
    "user": {
        "city": "Springfield"
    }
}

Output

Springfield

dot-notation-leading-dot

A leading dot is stripped before parsing; '.name' resolves identically to 'name'.

Template

{{ .name }}

Context

{
    "name": "Alice"
}

Output

Alice

Source fixture: render/identifier-formats.json