
Shopify Liquid Themes
Generate and edit Shopify Online Store 2.0 Liquid sections, blocks, and snippets with valid schema, LiquidDoc, and theme editor patterns.
Install
npx skills add https://github.com/benjaminsehl/liquid-skills --skill shopify-liquid-themesWhat is this skill?
- Maps sections vs blocks vs snippets with schema and {% render %} usage
- LiquidDoc headers and translation keys for merchant-editable settings
- Layout requirements: content_for_header and content_for_layout
- Prefers {% stylesheet %} and {% javascript %} over loose assets where appropriate
- JSON templates wiring sections to page types
Adoption & trust: 2.3k installs on skills.sh; 108 GitHub stars; 3/3 security scanners passed (skills.sh audits).
Recommended Skills
Frontend Designanthropics/skills
Vercel React Best Practicesvercel-labs/agent-skills
Remotion Best Practicesremotion-dev/skills
Vercel Composition Patternsvercel-labs/agent-skills
Develop Userscriptsxixu-me/skills
Next Best Practicesvercel-labs/next-skills
Journey fit
Common Questions / FAQ
Is Shopify Liquid Themes safe to install?
skills.sh reports 3 of 3 security scanners passed. Review the Security Audits panel on this page before installing in production.
SKILL.md
READMESKILL.md - Shopify Liquid Themes
# Shopify Liquid Themes ## Theme Architecture ``` . ├── sections/ # Full-width page modules with {% schema %} — hero, product grid, testimonials ├── blocks/ # Nestable components with {% schema %} — slides, feature items, text blocks ├── snippets/ # Reusable fragments via {% render %} — buttons, icons, image helpers ├── layout/ # Page wrappers (must include {{ content_for_header }} and {{ content_for_layout }}) ├── templates/ # JSON files defining which sections appear on each page type ├── config/ # Global theme settings (settings_schema.json, settings_data.json) ├── locales/ # Translation files (en.default.json, fr.json, etc.) └── assets/ # Static CSS, JS, images (prefer {% stylesheet %}/{% javascript %} instead) ``` ### When to use what | Need | Use | Why | |------|-----|-----| | Full-width customizable module | **Section** | Has `{% schema %}`, appears in editor, renders blocks | | Small nestable component with editor settings | **Block** | Has `{% schema %}`, can nest inside sections/blocks | | Reusable logic, not editable by merchant | **Snippet** | No schema, rendered via `{% render %}`, takes params | | Logic shared across blocks/snippets | **Snippet** | Blocks can't `{% render %}` other blocks | ## Liquid Syntax ### Delimiters - `{{ ... }}` — Output (prints a value) - `{{- ... -}}` — Output with whitespace trimming - `{% ... %}` — Logic tag (if, for, assign) — prints nothing - `{%- ... -%}` — Logic tag with whitespace trimming ### Operators **Comparison:** `==`, `!=`, `>`, `<`, `>=`, `<=` **Logical:** `and`, `or`, `contains` ### Critical Gotchas 1. **No parentheses** in conditions — use nested `{% if %}` instead 2. **No ternary** — always use `{% if cond %}value{% else %}other{% endif %}` 3. **`for` loops max 50 iterations** — use `{% paginate %}` for larger arrays 4. **`contains` only works with strings** — can't check objects in arrays 5. **`{% stylesheet %}`/`{% javascript %}` don't render Liquid** — no Liquid inside them 6. **Snippets can't access outer-scope variables** — pass them as render params 7. **`include` is deprecated** — always use `{% render 'snippet_name' %}` 8. **`{% liquid %}` tag** — multi-line logic without delimiters; use `echo` for output ### Variables ```liquid {% assign my_var = 'value' %} {% capture my_var %}computed {{ value }}{% endcapture %} {% increment counter %} {% decrement counter %} ``` ## Filter Quick Reference Filters are chained with `|`. Output type of one filter feeds input of next. **Array:** `compact`, `concat`, `find`, `find_index`, `first`, `has`, `join`, `last`, `map`, `reject`, `reverse`, `size`, `sort`, `sort_natural`, `sum`, `uniq`, `where` **String:** `append`, `capitalize`, `downcase`, `escape`, `handleize`, `lstrip`, `newline_to_br`, `prepend`, `remove`, `replace`, `rstrip`, `slice`, `split`, `strip`, `strip_html`, `truncate`, `truncatewords`, `upcase`, `url_decode`, `url_encode` **Math:** `abs`, `at_least`, `at_most`, `ceil`, `divided_by`, `floor`, `minus`, `modulo`, `plus`, `round`, `times` **Money:** `money`, `money_with_currency`, `money_without_currency`, `money_without_trailing_zeros` **Color:** `color_brightness`, `color_darken`, `color_lighten`, `color_mix`, `color_modify`, `color_saturate`, `color_desaturate`, `color_to_hex`, `color_to_hsl`, `color_to_rgb` **Media:** `image_url`, `image_tag`, `video_tag`, `external_video_tag`, `media_tag`, `model_viewer_tag` **URL:** `asset_url`, `asset_img_url`, `file_url`, `shopify_asset_url` **HTML:** `link_to`, `script_tag`, `stylesheet_tag`, `time_tag`, `placeholder_svg_tag` **Localization:** `t` (translate), `format_addre