Skip to content

Liquid: document partial dialect coverage and index capture declarations #2498

Open

Description

@Puma7

Liquid capture declarations are omitted while assign declarations are indexed. The language reference also labels Liquid as fully supported without describing its host/dialect boundaries. This is a feature/documentation request, not a claim that static analysis can reproduce every storefront.

{% assign existing = 'ok' %}
{% capture captured %}Hello{% endcapture %}

In v1.6.2/source main fc0da38f, existing appears as a variable and captured does not. capture is standard Liquid, independent of Shopify directories. The gap also affects multiline liquid blocks.

Closing scope for draft #2504:

  • Extract quoted/unquoted capture declarations with source positions, containment and comment/raw suppression; preserve assigns and literal render references.
  • Document the actual subset consistently in the README and language reference. The wording/status is a proposal for maintainer review.

Capture variables become searchable definitions, not links to every variable use. Declaration extraction is not complete dialect syntax validation.

Separate follow-ups, also related to #648: Jekyll include/file-extension rules, embedded JS/CSS, Shopify assets/static blocks and settings/translation consumers. Quoted Jekyll-style includes currently receive Shopify-shaped snippet paths; unquoted forms emit no reference. These need host-aware implementation and are not completed by this PR. Missing graph edges are not proof of unused template/data files.

Validation: all 30 capture tests pass, including standard and quoted forms, whitespace control and non-executing examples. The README control character reported during review is removed.

References: capture, dialects, Jekyll includes.

Activity

  1. changed the title [-]Define and extend Shopify Liquid cross-language coverage beyond render/section/assign[/-] [+]Feature request: document Liquid dialect coverage and extend deterministic dependencies[/+] on Oct 11, 2026
  2. changed the title [-]Feature request: document Liquid dialect coverage and extend deterministic dependencies[/-] [+]Liquid: document partial dialect coverage and index capture declarations[/+] on Oct 12, 2026
  3. Puma7 commented on Oct 12, 2026

    @Puma7
    Author

    Updated validation after the supplied review:

    #2504 now corrects the README control character, shortens the documentation and matcher, and passes all 30 capture cases. The closing scope remains declarations plus documented boundaries; variable-use edges, Jekyll/embedded/runtime support are explicit follow-ups. The PR retains Closes #2498.

  4. colbymchenry commented on Oct 22, 2026

    @colbymchenry
    Owner

    Thanks for the clear report and for #2504, which this follows closely.

    #2814 is merged to main. It indexes variables declared with {% capture %} the same way as {% assign %} ones, in both tag spellings and with quoted names, and skips captures inside {% comment %} and {% raw %} blocks. Search and codegraph_explore now find them. Unlike #2504, it leaves names containing - or . out for now, matching how assigned names are handled.

    The README and languages-page wording is in #2815, which is waiting on a maintainer decision, so this issue stays open until that's settled. The Jekyll, embedded-code and settings follow-ups you listed are separate features.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions