@salesforcedevs/sfdocs-liquid-lint-disabled-tags
v0.0.1-alpha
Published
Flag any usage of Liquid tags that the sfdocs runtime forbids.
Maintainers
Keywords
Readme
liquid-lint-disabled-tags
This Markdown plugin flags any usage of Liquid tags that the sfdocs runtime
explicitly disallows. The list is kept in lockstep with DISABLED_LIQUID_TAGS
in @salesforcedevs/sfdocs-doc-framework's runtime/liquid/tags/index.ts.
The forbidden tags are:
tablerow, render, case, when, unless, cycle, increment, decrement,
raw, layout, block, extends, break, continueWhy
At runtime each of these tags is registered as a DisabledTag whose render()
method throws. Catching them at lint time gives writers a clear error on the
exact line, instead of waiting for SSG/LWR to fail.
Activation
The rule activates only when a file's frontmatter declares
liquid.enabled: true, matching the runtime gate in
liquid-markdown-view-provider.ts.
Example violation
---
liquid:
enabled: true
---
{% case status %}
{% when "open" %} ... {% endcase %}Install & build
yarn install && yarn buildRelease versioning and commits are automated via Lerna when you merge the release PR.
