<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Yakhyo Ismoildjonov</title>
    <description>The latest articles on DEV Community by Yakhyo Ismoildjonov (@yakohere).</description>
    <link>https://dev.to/yakohere</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F501372%2Fcf501011-3e9f-47e0-960e-467067da13b2.jpeg</url>
      <title>DEV Community: Yakhyo Ismoildjonov</title>
      <link>https://dev.to/yakohere</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/yakohere"/>
    <language>en</language>
    <item>
      <title>The Ultimate Guide to Shopify Cart Debugging: How to Save Hours with Shopify Theme Devtools Cart Panel</title>
      <dc:creator>Yakhyo Ismoildjonov</dc:creator>
      <pubDate>Wed, 14 Jan 2026 06:12:54 +0000</pubDate>
      <link>https://dev.to/yakohere/the-ultimate-guide-to-shopify-cart-debugging-how-to-save-hours-with-shopify-theme-devtools-cart-1f70</link>
      <guid>https://dev.to/yakohere/the-ultimate-guide-to-shopify-cart-debugging-how-to-save-hours-with-shopify-theme-devtools-cart-1f70</guid>
      <description>&lt;p&gt;&lt;strong&gt;TL;DR:&lt;/strong&gt; Stop console.logging your cart state. Shopify Theme Devtools gives you a visual cart inspector, history tracking, test automation, and scenario management—all in your browser while developing themes.&lt;/p&gt;




&lt;h2&gt;
  
  
  Introduction: Why Cart Debugging is Painful
&lt;/h2&gt;

&lt;p&gt;If you've developed Shopify themes, you know the pain:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Manually adding products to test cart states&lt;/li&gt;
&lt;li&gt;Using &lt;code&gt;console.log({{ cart | json }})&lt;/code&gt; to debug&lt;/li&gt;
&lt;li&gt;Rebuilding complex carts after every page refresh&lt;/li&gt;
&lt;li&gt;No way to test edge cases like gift-with-purchase items or subscriptions&lt;/li&gt;
&lt;li&gt;Tracking down which JavaScript is modifying your cart&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Shopify Theme Devtools&lt;/strong&gt; solves all of this with a dedicated Cart Panel that transforms how you debug and test cart functionality.&lt;/p&gt;




&lt;h2&gt;
  
  
  What is Shopify Theme Devtools?
&lt;/h2&gt;

&lt;p&gt;Shopify Theme Devtools is an &lt;strong&gt;open-source, in-browser developer panel&lt;/strong&gt; for Shopify theme development. Think of it as Chrome DevTools, but specifically designed for Liquid and Shopify.&lt;/p&gt;

&lt;p&gt;The Cart Panel is one of its most powerful features—a complete cart management and debugging toolkit that runs directly in your development theme.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Key Features:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Real-time cart state inspection&lt;/li&gt;
&lt;li&gt;Visual cart history with diff tracking&lt;/li&gt;
&lt;li&gt;Saveable cart scenarios for testing&lt;/li&gt;
&lt;li&gt;Automated cart validation tests&lt;/li&gt;
&lt;li&gt;AJAX request interception&lt;/li&gt;
&lt;li&gt;One-click cart restoration&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  Getting Started
&lt;/h2&gt;

&lt;h3&gt;
  
  
  Installation
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;npx shopify-theme-devtools init
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This adds the Liquid snippet to your theme. The devtools only render on &lt;strong&gt;unpublished themes&lt;/strong&gt;, so your live store is never affected.&lt;/p&gt;

&lt;h3&gt;
  
  
  Accessing the Cart Panel
&lt;/h3&gt;

&lt;p&gt;Once installed, you'll see a floating devtools panel on your development theme. Click the &lt;strong&gt;Cart&lt;/strong&gt; tab to access all cart debugging features.&lt;/p&gt;




&lt;h2&gt;
  
  
  Feature 1: Real-Time Cart Inspector
&lt;/h2&gt;

&lt;h3&gt;
  
  
  The Problem
&lt;/h3&gt;

&lt;p&gt;Debugging cart state usually means adding &lt;code&gt;{{ cart | json }}&lt;/code&gt; to your template, refreshing, copying the JSON, and pasting it into a formatter. Repeat for every change.&lt;/p&gt;

&lt;h3&gt;
  
  
  The Solution
&lt;/h3&gt;

&lt;p&gt;The Cart Panel shows your complete cart state in a clean, interactive interface:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;At a glance, you see:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Total items and price&lt;/li&gt;
&lt;li&gt;Currency and total weight&lt;/li&gt;
&lt;li&gt;Active discount codes with savings&lt;/li&gt;
&lt;li&gt;Cart attributes and notes&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;For each line item:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Product thumbnail, title, and variant&lt;/li&gt;
&lt;li&gt;SKU and quantity&lt;/li&gt;
&lt;li&gt;Original price vs. discounted price (with percentage saved)&lt;/li&gt;
&lt;li&gt;Selling plan details for subscriptions&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Expandable Item Details
&lt;/h3&gt;

&lt;p&gt;Click any item to reveal:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Variant ID, Product ID, and Item Key&lt;/li&gt;
&lt;li&gt;Vendor and product type&lt;/li&gt;
&lt;li&gt;Complete line item properties&lt;/li&gt;
&lt;li&gt;Discount breakdowns by code&lt;/li&gt;
&lt;li&gt;Selling plan allocation details&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Quick Actions:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Copy Variant ID, Product ID, or Item Key to clipboard&lt;/li&gt;
&lt;li&gt;Duplicate item (preserves all properties)&lt;/li&gt;
&lt;li&gt;Remove item instantly&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Example Use Case
&lt;/h3&gt;

&lt;p&gt;You're debugging why a discount isn't applying correctly. Instead of digging through JSON:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Open Cart Panel&lt;/li&gt;
&lt;li&gt;Expand the item in question&lt;/li&gt;
&lt;li&gt;See the exact discount allocation and compare with expected values&lt;/li&gt;
&lt;li&gt;Notice the discount is applying to &lt;code&gt;line_price&lt;/code&gt; but your theme is displaying &lt;code&gt;original_line_price&lt;/code&gt;
&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;strong&gt;Time saved: 15+ minutes per debugging session&lt;/strong&gt;&lt;/p&gt;




&lt;h2&gt;
  
  
  Feature 2: Cart History &amp;amp; Time Travel
&lt;/h2&gt;

&lt;h3&gt;
  
  
  The Problem
&lt;/h3&gt;

&lt;p&gt;You've finally reproduced a cart bug after 10 minutes of adding products. You refresh the page to test your fix—and the cart state is gone or changed.&lt;/p&gt;

&lt;h3&gt;
  
  
  The Solution
&lt;/h3&gt;

&lt;p&gt;Cart History automatically tracks every cart change with timestamps and visual diffs.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;What gets tracked:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Items added (green)&lt;/li&gt;
&lt;li&gt;Items removed (red)&lt;/li&gt;
&lt;li&gt;Quantity changes (orange with old→new values)&lt;/li&gt;
&lt;li&gt;Attribute modifications&lt;/li&gt;
&lt;li&gt;Note changes&lt;/li&gt;
&lt;li&gt;Discount code applications&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  One-Click Restoration
&lt;/h3&gt;

&lt;p&gt;See a historical cart state you need? Click &lt;strong&gt;Restore&lt;/strong&gt; and the Cart Panel:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Clears your current cart&lt;/li&gt;
&lt;li&gt;Re-adds all items with their exact properties&lt;/li&gt;
&lt;li&gt;Restores cart attributes and notes&lt;/li&gt;
&lt;li&gt;Maintains selling plan allocations&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;strong&gt;The entire process takes ~2 seconds.&lt;/strong&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Example Use Case
&lt;/h3&gt;

&lt;p&gt;You're testing a "free gift at $100" promotion:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Build a cart worth $95&lt;/li&gt;
&lt;li&gt;Add a $10 item → gift appears&lt;/li&gt;
&lt;li&gt;Test your Liquid display logic&lt;/li&gt;
&lt;li&gt;Realize you need to test the $95 state again&lt;/li&gt;
&lt;li&gt;Click &lt;strong&gt;Restore&lt;/strong&gt; on the $95 history entry&lt;/li&gt;
&lt;li&gt;Continue testing&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;strong&gt;Time saved: 5-10 minutes per cart rebuild&lt;/strong&gt;&lt;/p&gt;




&lt;h2&gt;
  
  
  Feature 3: Cart Scenarios (Saved Cart States)
&lt;/h2&gt;

&lt;h3&gt;
  
  
  The Problem
&lt;/h3&gt;

&lt;p&gt;You have 8 different cart configurations you need to test:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Empty cart&lt;/li&gt;
&lt;li&gt;Single item&lt;/li&gt;
&lt;li&gt;Multiple items&lt;/li&gt;
&lt;li&gt;Items with properties (personalization)&lt;/li&gt;
&lt;li&gt;Subscription items&lt;/li&gt;
&lt;li&gt;Gift-with-purchase items&lt;/li&gt;
&lt;li&gt;Mixed cart with discounts&lt;/li&gt;
&lt;li&gt;Maximum quantity cart&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Rebuilding these manually for every test cycle is exhausting.&lt;/p&gt;

&lt;h3&gt;
  
  
  The Solution
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Cart Scenarios&lt;/strong&gt; let you save, name, and instantly load predefined cart states.&lt;/p&gt;

&lt;h3&gt;
  
  
  Creating a Scenario
&lt;/h3&gt;

&lt;ol&gt;
&lt;li&gt;Build your desired cart state&lt;/li&gt;
&lt;li&gt;Click &lt;strong&gt;Scenarios&lt;/strong&gt; → &lt;strong&gt;Save Current Cart&lt;/strong&gt;
&lt;/li&gt;
&lt;li&gt;Name it (e.g., "GWP Test - $100 threshold")&lt;/li&gt;
&lt;li&gt;The scenario saves all items, quantities, properties, attributes, and notes&lt;/li&gt;
&lt;/ol&gt;

&lt;h3&gt;
  
  
  Loading a Scenario
&lt;/h3&gt;

&lt;ol&gt;
&lt;li&gt;Click &lt;strong&gt;Scenarios&lt;/strong&gt;
&lt;/li&gt;
&lt;li&gt;Select your saved scenario&lt;/li&gt;
&lt;li&gt;Choose to &lt;strong&gt;clear cart first&lt;/strong&gt; or &lt;strong&gt;add to existing&lt;/strong&gt;
&lt;/li&gt;
&lt;li&gt;Cart is populated instantly&lt;/li&gt;
&lt;/ol&gt;

&lt;h3&gt;
  
  
  Scenario Editor
&lt;/h3&gt;

&lt;p&gt;Need to tweak a scenario without rebuilding the cart?&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Add/remove items by variant ID&lt;/li&gt;
&lt;li&gt;Modify quantities&lt;/li&gt;
&lt;li&gt;Add line item properties&lt;/li&gt;
&lt;li&gt;Set cart attributes&lt;/li&gt;
&lt;li&gt;Include cart notes&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Import/Export
&lt;/h3&gt;

&lt;p&gt;Share scenarios with your team:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="err"&gt;//&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="err"&gt;Exported&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="err"&gt;scenario&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="err"&gt;file&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"name"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"GWP Test Cart"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"items"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"variant_id"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"12345678"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"quantity"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="mi"&gt;2&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"properties"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"_is_gwp"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"true"&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="p"&gt;],&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"attributes"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"gift_message"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"Happy Birthday!"&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;},&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"note"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"Test order - do not fulfill"&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Example Use Case
&lt;/h3&gt;

&lt;p&gt;Your QA team needs to test 12 different cart states for a new promotion:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Developer creates all 12 scenarios&lt;/li&gt;
&lt;li&gt;Exports as JSON file&lt;/li&gt;
&lt;li&gt;QA imports into their devtools&lt;/li&gt;
&lt;li&gt;QA can now test all 12 states in under a minute&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;strong&gt;Time saved: Hours of manual cart building across team members&lt;/strong&gt;&lt;/p&gt;




&lt;h2&gt;
  
  
  Feature 4: Automated Cart Tests
&lt;/h2&gt;

&lt;h3&gt;
  
  
  The Problem
&lt;/h3&gt;

&lt;p&gt;Cart validation logic is complex. Gift-with-purchase items need specific properties. Quantity limits must be enforced. Bundles require companion products. How do you catch these issues before they reach production?&lt;/p&gt;

&lt;h3&gt;
  
  
  The Solution
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Cart Tests&lt;/strong&gt; let you define validation rules that run automatically against your cart state.&lt;/p&gt;

&lt;h3&gt;
  
  
  Four Rule Types
&lt;/h3&gt;

&lt;h4&gt;
  
  
  1. Property Dependency Rules
&lt;/h4&gt;

&lt;p&gt;&lt;em&gt;"If item has property X, it must also have properties Y and Z"&lt;/em&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;IF item has property "_is_gwp" = "true"
THEN item MUST have properties: "_gwp_price", "_gwp_source", "_gwp_campaign"
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Use cases:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Gift-with-purchase validation&lt;/li&gt;
&lt;li&gt;Personalization requirements&lt;/li&gt;
&lt;li&gt;Pre-order expected ship dates&lt;/li&gt;
&lt;li&gt;Custom product data integrity&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  2. Field Value Rules
&lt;/h4&gt;

&lt;p&gt;&lt;em&gt;"If item field equals X, then another field must equal Y"&lt;/em&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;IF item product_type = "Gift Card"
THEN item quantity MUST equal 1
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Use cases:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Gift card quantity limits&lt;/li&gt;
&lt;li&gt;Digital product shipping flags&lt;/li&gt;
&lt;li&gt;SKU requirements&lt;/li&gt;
&lt;li&gt;Subscription validation&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  3. Cart Composition Rules
&lt;/h4&gt;

&lt;p&gt;&lt;em&gt;"If cart contains item X, cart must also contain item Y"&lt;/em&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;IF cart contains item with product_type = "Electronics"
THEN cart MUST contain item with product_type = "Warranty"
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Use cases:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Required accessories&lt;/li&gt;
&lt;li&gt;Bundle completeness&lt;/li&gt;
&lt;li&gt;Warranty requirements&lt;/li&gt;
&lt;li&gt;Cross-sell validation&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  4. Quantity Rules
&lt;/h4&gt;

&lt;p&gt;&lt;em&gt;"Item/cart quantities must meet min/max/multiple constraints"&lt;/em&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;SCOPE: per-item
MAX: 10
(No item can have quantity &amp;gt; 10)
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;





&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;SCOPE: cart-total
FILTER: product_type = "Sample"
MAX: 3
(Maximum 3 sample products in cart)
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Use cases:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Per-item limits&lt;/li&gt;
&lt;li&gt;Cart maximums&lt;/li&gt;
&lt;li&gt;Bulk order minimums (B2B)&lt;/li&gt;
&lt;li&gt;Sample product limits&lt;/li&gt;
&lt;li&gt;Pack quantity enforcement (multiples of 6)&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Pre-Built Templates
&lt;/h3&gt;

&lt;p&gt;Don't want to configure from scratch? Choose from 13 pre-built templates:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;code&gt;[Property] GWP Validation&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;[Property] Personalization Check&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;[Property] Pre-order Validation&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;[Field] Gift Card Qty = 1&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;[Field] Subscription Valid&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;[Field] Digital Products Check&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;[Field] SKU Required&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;[Composition] Warranty Required&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;[Composition] Bundle Check&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;[Qty] Max Per Item (10)&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;[Qty] Cart Max (50 items)&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;[Qty] Pack of 6 Only&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;[Qty] Samples Max 3&lt;/code&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Auto-Run Tests
&lt;/h3&gt;

&lt;p&gt;Enable &lt;strong&gt;Auto-run&lt;/strong&gt; and tests execute automatically whenever your cart changes. Failed items are highlighted with a red border directly in the cart display.&lt;/p&gt;

&lt;h3&gt;
  
  
  Test Results
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Summary shows pass/fail count&lt;/li&gt;
&lt;li&gt;Failed tests show detailed error messages&lt;/li&gt;
&lt;li&gt;Specific items causing failures are identified&lt;/li&gt;
&lt;li&gt;First 5 failures displayed with "+N more" indicator&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Example Use Case
&lt;/h3&gt;

&lt;p&gt;You're implementing a gift-with-purchase promotion:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Create a test: "GWP items must have &lt;code&gt;_gwp_price&lt;/code&gt; property"&lt;/li&gt;
&lt;li&gt;Enable auto-run&lt;/li&gt;
&lt;li&gt;Add a GWP item to cart&lt;/li&gt;
&lt;li&gt;Test immediately fails—missing required property&lt;/li&gt;
&lt;li&gt;Fix your GWP logic to include the property&lt;/li&gt;
&lt;li&gt;Test passes automatically&lt;/li&gt;
&lt;li&gt;Ship with confidence&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;strong&gt;Time saved: Catching bugs before they reach production = priceless&lt;/strong&gt;&lt;/p&gt;




&lt;h2&gt;
  
  
  Feature 5: Quick Cart Actions
&lt;/h2&gt;

&lt;h3&gt;
  
  
  Add Items Instantly
&lt;/h3&gt;

&lt;p&gt;No need to browse to product pages. Enter a &lt;strong&gt;variant ID&lt;/strong&gt; and &lt;strong&gt;quantity&lt;/strong&gt;, click &lt;strong&gt;Add&lt;/strong&gt;, and the item is in your cart.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Variant ID: 12345678901234
Quantity: 2
[Add]
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Apply Discount Codes
&lt;/h3&gt;

&lt;p&gt;Test discount logic directly from the panel without going through checkout:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Discount Code: SAVE20
[Apply]
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Cart Permalink
&lt;/h3&gt;

&lt;p&gt;Need to share a specific cart state? Click &lt;strong&gt;Link&lt;/strong&gt; to copy a permalink:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;https://yourstore.com/cart/12345678:2,87654321:1
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Export Cart JSON
&lt;/h3&gt;

&lt;p&gt;Click &lt;strong&gt;Export&lt;/strong&gt; to download your complete cart state as JSON for documentation or bug reports.&lt;/p&gt;




&lt;h2&gt;
  
  
  Feature 6: Network Request Tracking
&lt;/h2&gt;

&lt;h3&gt;
  
  
  The Problem
&lt;/h3&gt;

&lt;p&gt;Something is modifying your cart unexpectedly. Is it a third-party app? A theme script? A Shopify feature?&lt;/p&gt;

&lt;h3&gt;
  
  
  The Solution
&lt;/h3&gt;

&lt;p&gt;The Cart Panel intercepts and logs all cart-related AJAX requests:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Tracked endpoints:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;code&gt;/cart.js&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;/cart/add.js&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;/cart/update.js&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;/cart/change.js&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;/cart/clear.js&lt;/code&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;For each request, you see:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;HTTP method and status&lt;/li&gt;
&lt;li&gt;Request/response timing&lt;/li&gt;
&lt;li&gt;Request body and headers&lt;/li&gt;
&lt;li&gt;Response data&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Source identification&lt;/strong&gt; (which script made the request)&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Request Blocking
&lt;/h3&gt;

&lt;p&gt;Found a rogue script modifying your cart? &lt;strong&gt;Block requests by source&lt;/strong&gt; to isolate the issue:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Identify the problematic request&lt;/li&gt;
&lt;li&gt;Click &lt;strong&gt;Block Source&lt;/strong&gt;
&lt;/li&gt;
&lt;li&gt;Future requests from that script are prevented&lt;/li&gt;
&lt;li&gt;Continue debugging without interference&lt;/li&gt;
&lt;/ol&gt;




&lt;h2&gt;
  
  
  Best Practices
&lt;/h2&gt;

&lt;h3&gt;
  
  
  1. Create Scenario Libraries
&lt;/h3&gt;

&lt;p&gt;Build a comprehensive set of scenarios for your store:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;├── Basic States
│   ├── Empty cart
│   ├── Single item
│   └── Multiple items
├── Edge Cases
│   ├── Max quantity (per item)
│   ├── Max items (cart limit)
│   └── Zero-price items
├── Features
│   ├── Gift with purchase
│   ├── Subscription items
│   ├── Personalized items
│   └── Pre-order items
└── Promotions
    ├── Percentage discount
    ├── Fixed amount discount
    ├── Free shipping threshold
    └── BOGO promotion
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  2. Write Tests for Business Rules
&lt;/h3&gt;

&lt;p&gt;Document your business logic as automated tests:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Business Rule&lt;/th&gt;
&lt;th&gt;Test Type&lt;/th&gt;
&lt;th&gt;Configuration&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Gift cards qty = 1&lt;/td&gt;
&lt;td&gt;Field Value&lt;/td&gt;
&lt;td&gt;
&lt;code&gt;product_type = "Gift Card"&lt;/code&gt; → &lt;code&gt;quantity = 1&lt;/code&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;GWP has tracking&lt;/td&gt;
&lt;td&gt;Property Dependency&lt;/td&gt;
&lt;td&gt;
&lt;code&gt;_is_gwp = true&lt;/code&gt; → requires &lt;code&gt;_gwp_source&lt;/code&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Electronics need warranty&lt;/td&gt;
&lt;td&gt;Cart Composition&lt;/td&gt;
&lt;td&gt;
&lt;code&gt;product_type = "Electronics"&lt;/code&gt; → requires &lt;code&gt;product_type = "Warranty"&lt;/code&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Max 3 samples&lt;/td&gt;
&lt;td&gt;Quantity&lt;/td&gt;
&lt;td&gt;
&lt;code&gt;cart-total&lt;/code&gt;, &lt;code&gt;max: 3&lt;/code&gt;, filter: &lt;code&gt;product_type = "Sample"&lt;/code&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;h3&gt;
  
  
  3. Use History for Regression Testing
&lt;/h3&gt;

&lt;ol&gt;
&lt;li&gt;Build the cart state for your bug&lt;/li&gt;
&lt;li&gt;Fix the bug&lt;/li&gt;
&lt;li&gt;Use History to restore the original state&lt;/li&gt;
&lt;li&gt;Verify the fix&lt;/li&gt;
&lt;li&gt;Save as a scenario for future regression testing&lt;/li&gt;
&lt;/ol&gt;

&lt;h3&gt;
  
  
  4. Share Scenarios with Your Team
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Export scenarios as JSON&lt;/li&gt;
&lt;li&gt;Commit to your repository&lt;/li&gt;
&lt;li&gt;Import on each developer's machine&lt;/li&gt;
&lt;li&gt;Everyone can test the same edge cases&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  5. Enable Auto-Run Tests During Development
&lt;/h3&gt;

&lt;p&gt;Keep tests running automatically while you code. Instant feedback when something breaks.&lt;/p&gt;




&lt;h2&gt;
  
  
  Comparison: Before vs. After
&lt;/h2&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Task&lt;/th&gt;
&lt;th&gt;Without Devtools&lt;/th&gt;
&lt;th&gt;With Cart Panel&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Inspect cart state&lt;/td&gt;
&lt;td&gt;Add Liquid, refresh, copy JSON, format&lt;/td&gt;
&lt;td&gt;Click Cart tab&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Rebuild specific cart&lt;/td&gt;
&lt;td&gt;5-10 min manual work&lt;/td&gt;
&lt;td&gt;2 seconds (scenario load)&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Test 10 cart states&lt;/td&gt;
&lt;td&gt;50-100 minutes&lt;/td&gt;
&lt;td&gt;5 minutes&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Track cart changes&lt;/td&gt;
&lt;td&gt;Custom logging code&lt;/td&gt;
&lt;td&gt;Automatic history&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Validate GWP logic&lt;/td&gt;
&lt;td&gt;Manual testing&lt;/td&gt;
&lt;td&gt;Automated tests&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Find rogue cart scripts&lt;/td&gt;
&lt;td&gt;Console debugging&lt;/td&gt;
&lt;td&gt;Request tracking&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Share cart states&lt;/td&gt;
&lt;td&gt;Screenshots, instructions&lt;/td&gt;
&lt;td&gt;JSON export&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;




&lt;h2&gt;
  
  
  Common Questions
&lt;/h2&gt;

&lt;h3&gt;
  
  
  Does this work on live stores?
&lt;/h3&gt;

&lt;p&gt;No. The devtools only render on &lt;strong&gt;unpublished themes&lt;/strong&gt; for security.&lt;/p&gt;

&lt;h3&gt;
  
  
  Does it modify my theme code?
&lt;/h3&gt;

&lt;p&gt;It adds a single Liquid snippet that conditionally loads the devtools JavaScript.&lt;/p&gt;

&lt;h3&gt;
  
  
  Can I use it with any Shopify plan?
&lt;/h3&gt;

&lt;p&gt;Yes. It works with Basic, Shopify, Advanced, and Plus plans.&lt;/p&gt;

&lt;h3&gt;
  
  
  Is it free?
&lt;/h3&gt;

&lt;p&gt;Yes. Shopify Theme Devtools is open source.&lt;/p&gt;




&lt;h2&gt;
  
  
  Conclusion
&lt;/h2&gt;

&lt;p&gt;The Cart Panel in Shopify Theme Devtools transforms cart debugging from a tedious, time-consuming task into a streamlined workflow. Whether you're:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Debugging a discount issue&lt;/li&gt;
&lt;li&gt;Testing gift-with-purchase logic&lt;/li&gt;
&lt;li&gt;Validating subscription cart behavior&lt;/li&gt;
&lt;li&gt;Building complex promotional carts&lt;/li&gt;
&lt;li&gt;Catching cart validation bugs&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;...you'll save hours of development time.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Get started:&lt;/strong&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;npx shopify-theme-devtools init
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  Resources
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://github.com/yakohere/shopify-theme-devtools" rel="noopener noreferrer"&gt;GitHub Repository&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;




&lt;p&gt;&lt;em&gt;Tags: #shopify #shopifythemes #shopifydevelopment #liquid #ecommerce #webdevelopment #javascript #debugging #devtools #tutorial&lt;/em&gt;&lt;/p&gt;

</description>
      <category>shopify</category>
      <category>shopifydev</category>
      <category>shopifyliquid</category>
    </item>
    <item>
      <title>How to Debug Shopify Liquid: A Complete Guide</title>
      <dc:creator>Yakhyo Ismoildjonov</dc:creator>
      <pubDate>Wed, 14 Jan 2026 05:47:45 +0000</pubDate>
      <link>https://dev.to/yakohere/how-to-debug-shopify-liquid-a-complete-guide-2655</link>
      <guid>https://dev.to/yakohere/how-to-debug-shopify-liquid-a-complete-guide-2655</guid>
      <description>&lt;p&gt;Debugging Shopify Liquid templates is notoriously difficult. There's no built-in debugger, no breakpoints, no step-through execution. When something breaks, you're often left staring at a blank page or cryptic error message with no clear path forward.&lt;/p&gt;

&lt;p&gt;This guide covers every method for debugging Liquid — from basic techniques to advanced tooling — so you can diagnose and fix issues faster.&lt;/p&gt;




&lt;h2&gt;
  
  
  Why Is Liquid Hard to Debug?
&lt;/h2&gt;

&lt;p&gt;Liquid is a templating language, not a programming language. It runs server-side on Shopify's infrastructure, which means:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;No browser DevTools&lt;/strong&gt; — You can't inspect Liquid like you inspect JavaScript&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;No console.log&lt;/strong&gt; — There's no native way to print debug output&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Silent failures&lt;/strong&gt; — Many errors render as empty strings instead of error messages&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;No stack traces&lt;/strong&gt; — When something breaks, you don't know where&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Server-rendered&lt;/strong&gt; — Every change requires a page refresh to test&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;This makes debugging a slow, frustrating process of trial and error.&lt;/p&gt;




&lt;h2&gt;
  
  
  Method 1: The JSON Filter
&lt;/h2&gt;

&lt;p&gt;The most common debugging technique is outputting objects as JSON:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight liquid"&gt;&lt;code&gt;&lt;span class="cp"&gt;{{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;product&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;|&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nf"&gt;json&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;}}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This renders the entire product object as a JSON string in your HTML. You can then:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;View page source or inspect element&lt;/li&gt;
&lt;li&gt;Copy the JSON output&lt;/li&gt;
&lt;li&gt;Paste into a JSON formatter to read it&lt;/li&gt;
&lt;/ol&gt;

&lt;h3&gt;
  
  
  Limitations
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Clutters your HTML output&lt;/li&gt;
&lt;li&gt;Easy to forget and leave in production code&lt;/li&gt;
&lt;li&gt;Requires refreshing the page for every change&lt;/li&gt;
&lt;li&gt;Large objects are hard to navigate&lt;/li&gt;
&lt;li&gt;No syntax highlighting or search&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Better: Wrap in a script tag
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight liquid"&gt;&lt;code&gt;&amp;lt;script&amp;gt;
  console.log('Product:', &lt;span class="cp"&gt;{{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;product&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;|&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nf"&gt;json&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;}}&lt;/span&gt;);
&amp;lt;/script&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now you can view it in browser DevTools console with proper formatting.&lt;/p&gt;




&lt;h2&gt;
  
  
  Method 2: Shopify Theme Check
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://github.com/Shopify/theme-check" rel="noopener noreferrer"&gt;Theme Check&lt;/a&gt; is Shopify's official linter for Liquid. It catches common errors before you deploy.&lt;/p&gt;

&lt;h3&gt;
  
  
  Installation
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="c"&gt;# Via Shopify CLI&lt;/span&gt;
shopify theme check

&lt;span class="c"&gt;# Or standalone&lt;/span&gt;
gem &lt;span class="nb"&gt;install &lt;/span&gt;theme-check
theme-check
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  What it catches
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Undefined objects and variables&lt;/li&gt;
&lt;li&gt;Deprecated tags and filters&lt;/li&gt;
&lt;li&gt;Missing template files&lt;/li&gt;
&lt;li&gt;Performance issues (too many API calls)&lt;/li&gt;
&lt;li&gt;Translation key errors&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Limitations
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Static analysis only — doesn't catch runtime errors&lt;/li&gt;
&lt;li&gt;Can't inspect actual data values&lt;/li&gt;
&lt;li&gt;Runs in terminal, not in browser&lt;/li&gt;
&lt;li&gt;No live debugging&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  Method 3: Shopify's Built-in Error Messages
&lt;/h2&gt;

&lt;p&gt;Liquid does surface some errors directly in the HTML output. Look for:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Liquid error: undefined method 'title' for nil:NilClass
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;





&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Liquid syntax error: Unknown tag 'endfor'
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  How to find them
&lt;/h3&gt;

&lt;ol&gt;
&lt;li&gt;View page source (&lt;code&gt;Cmd+U&lt;/code&gt; / &lt;code&gt;Ctrl+U&lt;/code&gt;)&lt;/li&gt;
&lt;li&gt;Search for "Liquid error" or "Liquid syntax"&lt;/li&gt;
&lt;li&gt;The error message usually indicates the file and line&lt;/li&gt;
&lt;/ol&gt;

&lt;h3&gt;
  
  
  Common error patterns
&lt;/h3&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Error&lt;/th&gt;
&lt;th&gt;Cause&lt;/th&gt;
&lt;th&gt;Fix&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;undefined method for nil:NilClass&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Accessing property on null object&lt;/td&gt;
&lt;td&gt;Add &lt;code&gt;{% if object %}&lt;/code&gt; check&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;Unknown tag&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Typo in tag name&lt;/td&gt;
&lt;td&gt;Check spelling (&lt;code&gt;endif&lt;/code&gt; not &lt;code&gt;end if&lt;/code&gt;)&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;Could not find snippet&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Missing snippet file&lt;/td&gt;
&lt;td&gt;Create the file or fix the path&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;Invalid JSON&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Malformed JSON in section schema&lt;/td&gt;
&lt;td&gt;Validate your JSON syntax&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;




&lt;h2&gt;
  
  
  Method 4: Preview Inspector (Theme Editor)
&lt;/h2&gt;

&lt;p&gt;Shopify's theme customizer has a basic inspector:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Open theme customizer&lt;/li&gt;
&lt;li&gt;Click on a section&lt;/li&gt;
&lt;li&gt;View available settings and blocks&lt;/li&gt;
&lt;/ol&gt;

&lt;h3&gt;
  
  
  Limitations
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Only shows section settings, not Liquid objects&lt;/li&gt;
&lt;li&gt;Can't inspect product, cart, or collection data&lt;/li&gt;
&lt;li&gt;No expression evaluation&lt;/li&gt;
&lt;li&gt;No error detection&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  Method 5: Browser DevTools (for JavaScript)
&lt;/h2&gt;

&lt;p&gt;If your Liquid outputs data for JavaScript consumption, you can debug the JavaScript side:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight liquid"&gt;&lt;code&gt;&amp;lt;script&amp;gt;
  window.productData = &lt;span class="cp"&gt;{{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;product&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;|&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nf"&gt;json&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;}}&lt;/span&gt;;
&amp;lt;/script&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Then in browser console:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="nx"&gt;console&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;log&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;productData&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;title&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="nx"&gt;console&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;log&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;productData&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;variants&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;].&lt;/span&gt;&lt;span class="nx"&gt;price&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Limitations
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Only works for data you explicitly expose&lt;/li&gt;
&lt;li&gt;Can't access Liquid-only objects like &lt;code&gt;template&lt;/code&gt; or &lt;code&gt;request&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;Requires modifying your code to expose data&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  Method 6: In-Browser Liquid DevTools
&lt;/h2&gt;

&lt;p&gt;The most comprehensive solution is using dedicated developer tools that run in the browser.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/yakohere/shopify-theme-devtools" rel="noopener noreferrer"&gt;Shopify Theme Devtools&lt;/a&gt; is an open-source panel that provides:&lt;/p&gt;

&lt;h3&gt;
  
  
  Objects Inspector
&lt;/h3&gt;

&lt;p&gt;Browse all Liquid objects in a collapsible tree view:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;code&gt;shop&lt;/code&gt; — Store settings, currency, locale&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;product&lt;/code&gt; — Current product with variants, images, metafields&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;collection&lt;/code&gt; — Collection data with products&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;cart&lt;/code&gt; — Live cart state with items and attributes&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;customer&lt;/code&gt; — Logged-in customer data&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;template&lt;/code&gt; — Current template name and directory&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;request&lt;/code&gt; — Page URL, host, path&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Click any property to copy its Liquid path.&lt;/p&gt;

&lt;h3&gt;
  
  
  Live Expression Evaluator
&lt;/h3&gt;

&lt;p&gt;Test Liquid expressions without refreshing:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;&amp;gt; product.title
"Classic Cotton T-Shirt"

&amp;gt; product.price | money
"$29.99"

&amp;gt; cart.items | size
3

&amp;gt; product.variants | first | json
{"id": 12345, "title": "Small / Blue", ...}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Supports 50+ Liquid filters including &lt;code&gt;money&lt;/code&gt;, &lt;code&gt;money_with_currency&lt;/code&gt;, &lt;code&gt;img_url&lt;/code&gt;, &lt;code&gt;asset_url&lt;/code&gt;, and more.&lt;/p&gt;

&lt;h3&gt;
  
  
  Automatic Error Detection
&lt;/h3&gt;

&lt;p&gt;Scans the page for common Liquid issues:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Error Type&lt;/th&gt;
&lt;th&gt;Example&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Liquid errors&lt;/td&gt;
&lt;td&gt;&lt;code&gt;Liquid error: undefined method 'size'&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Syntax errors&lt;/td&gt;
&lt;td&gt;&lt;code&gt;Liquid syntax error: Unknown tag 'endif'&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Drop object leaks&lt;/td&gt;
&lt;td&gt;&lt;code&gt;#&amp;lt;ProductDrop:0x00007f...&amp;gt;&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Missing snippets&lt;/td&gt;
&lt;td&gt;&lt;code&gt;Could not find snippet 'missing-file'&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Schema errors&lt;/td&gt;
&lt;td&gt;Invalid JSON in section schema&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;JSON filter errors&lt;/td&gt;
&lt;td&gt;&lt;code&gt;{"error":"not found"}&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;Each error includes a suggested fix.&lt;/p&gt;

&lt;h3&gt;
  
  
  Cart Debugging
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;View live cart state with all items and properties&lt;/li&gt;
&lt;li&gt;Adjust quantities without leaving the panel&lt;/li&gt;
&lt;li&gt;Save and restore cart snapshots&lt;/li&gt;
&lt;li&gt;View cart history with timestamps&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Installation
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;npx shopify-theme-devtools init &lt;span class="nt"&gt;--inject&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Then press &lt;code&gt;Cmd+Shift+D&lt;/code&gt; (Mac) or &lt;code&gt;Ctrl+Shift+D&lt;/code&gt; (Windows) to open.&lt;/p&gt;

&lt;p&gt;Only loads on development themes — safe to commit to your repository.&lt;/p&gt;




&lt;h2&gt;
  
  
  Common Liquid Errors and Solutions
&lt;/h2&gt;

&lt;h3&gt;
  
  
  1. "undefined method for nil:NilClass"
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Cause:&lt;/strong&gt; Accessing a property on an object that doesn't exist.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight liquid"&gt;&lt;code&gt;&amp;lt;!-- This breaks if product is nil --&amp;gt;
&lt;span class="cp"&gt;{{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;product&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nv"&gt;title&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;}}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Fix:&lt;/strong&gt; Always check if the object exists first.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight liquid"&gt;&lt;code&gt;&lt;span class="cp"&gt;{%&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;if&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;product&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;%}&lt;/span&gt;
  &lt;span class="cp"&gt;{{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;product&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nv"&gt;title&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;}}&lt;/span&gt;
&lt;span class="cp"&gt;{%&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;endif&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;%}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  2. "Unknown tag"
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Cause:&lt;/strong&gt; Typo in a Liquid tag name.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight liquid"&gt;&lt;code&gt;&amp;lt;!-- Wrong --&amp;gt;
&lt;span class="cp"&gt;{%&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;end&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;if&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;%}&lt;/span&gt;

&amp;lt;!-- Correct --&amp;gt;
&lt;span class="cp"&gt;{%&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;endif&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;%}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  3. Drop object leak (#&lt;a&gt;ProductDrop:0x...&lt;/a&gt;)
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Cause:&lt;/strong&gt; Outputting a Liquid object without the &lt;code&gt;json&lt;/code&gt; filter.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight liquid"&gt;&lt;code&gt;&amp;lt;!-- Wrong — renders as #&amp;lt;ProductDrop:0x...&amp;gt; --&amp;gt;
&amp;lt;script&amp;gt;
  const product = &lt;span class="cp"&gt;{{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;product&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;}}&lt;/span&gt;;
&amp;lt;/script&amp;gt;

&amp;lt;!-- Correct --&amp;gt;
&amp;lt;script&amp;gt;
  const product = &lt;span class="cp"&gt;{{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;product&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;|&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nf"&gt;json&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;}}&lt;/span&gt;;
&amp;lt;/script&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  4. "Could not find snippet"
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Cause:&lt;/strong&gt; Rendering a snippet that doesn't exist.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight liquid"&gt;&lt;code&gt;&lt;span class="cp"&gt;{%&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;render&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s1"&gt;'non-existent-snippet'&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;%}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Fix:&lt;/strong&gt; Check the snippet filename and ensure it's in the &lt;code&gt;snippets/&lt;/code&gt; folder.&lt;/p&gt;

&lt;h3&gt;
  
  
  5. Empty output (no error)
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Cause:&lt;/strong&gt; Variable is nil or empty, but Liquid doesn't error — it just outputs nothing.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Debug:&lt;/strong&gt; Use the &lt;code&gt;inspect&lt;/code&gt; filter or JSON output:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight liquid"&gt;&lt;code&gt;&lt;span class="cp"&gt;{{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;my_variable&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;|&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nf"&gt;json&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;}}&lt;/span&gt;
&amp;lt;!-- Shows "null" if nil, actual value otherwise --&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  6. "Invalid JSON in schema"
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Cause:&lt;/strong&gt; Section schema has malformed JSON.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight liquid"&gt;&lt;code&gt;&lt;span class="cp"&gt;{%&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;schema&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;%}&lt;/span&gt;
{
  "name": "My Section",
  "settings": [
    {
      "type": "text",
      "id": "title"
      &amp;lt;!-- Missing comma here --&amp;gt;
      "label": "Title"
    }
  ]
}
&lt;span class="cp"&gt;{%&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;endschema&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;%}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Fix:&lt;/strong&gt; Validate your JSON at &lt;a href="https://jsonlint.com/" rel="noopener noreferrer"&gt;jsonlint.com&lt;/a&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  7. Incorrect money formatting
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Cause:&lt;/strong&gt; Using raw price values without the money filter.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight liquid"&gt;&lt;code&gt;&amp;lt;!-- Wrong — outputs "2999" --&amp;gt;
&lt;span class="cp"&gt;{{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;product&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nv"&gt;price&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;}}&lt;/span&gt;

&amp;lt;!-- Correct — outputs "$29.99" --&amp;gt;
&lt;span class="cp"&gt;{{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;product&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nv"&gt;price&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;|&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nf"&gt;money&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;}}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  8. Array index out of bounds
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Cause:&lt;/strong&gt; Accessing an array index that doesn't exist.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight liquid"&gt;&lt;code&gt;&amp;lt;!-- Breaks if product has fewer than 3 images --&amp;gt;
&lt;span class="cp"&gt;{{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;product&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nv"&gt;images&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="mi"&gt;2&lt;/span&gt;&lt;span class="p"&gt;].&lt;/span&gt;&lt;span class="nv"&gt;src&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;}}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Fix:&lt;/strong&gt; Check array size first:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight liquid"&gt;&lt;code&gt;&lt;span class="cp"&gt;{%&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;if&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;product&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nv"&gt;images&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;size&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;&amp;gt;&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="mi"&gt;2&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;%}&lt;/span&gt;
  &lt;span class="cp"&gt;{{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;product&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nv"&gt;images&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="mi"&gt;2&lt;/span&gt;&lt;span class="p"&gt;].&lt;/span&gt;&lt;span class="nv"&gt;src&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;}}&lt;/span&gt;
&lt;span class="cp"&gt;{%&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;endif&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;%}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  Debugging Workflow: A Step-by-Step Process
&lt;/h2&gt;

&lt;p&gt;When you encounter an issue, follow this process:&lt;/p&gt;

&lt;h3&gt;
  
  
  Step 1: Check for visible errors
&lt;/h3&gt;

&lt;p&gt;Search your page source for "Liquid error" or "Liquid syntax error".&lt;/p&gt;

&lt;h3&gt;
  
  
  Step 2: Isolate the problem
&lt;/h3&gt;

&lt;p&gt;Comment out sections of code until the error disappears:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight liquid"&gt;&lt;code&gt;&lt;span class="cp"&gt;{%&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;comment&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;%}&lt;/span&gt;&lt;span class="c"&gt;
  {{ potentially_broken_code }}
&lt;/span&gt;&lt;span class="cp"&gt;{%&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;endcomment&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;%}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Step 3: Inspect the data
&lt;/h3&gt;

&lt;p&gt;Use JSON output or a devtools panel to see what data is actually available:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight liquid"&gt;&lt;code&gt;&lt;span class="cp"&gt;{{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;product&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;|&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nf"&gt;json&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;}}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Step 4: Verify object existence
&lt;/h3&gt;

&lt;p&gt;Add existence checks around the problematic code:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight liquid"&gt;&lt;code&gt;&lt;span class="cp"&gt;{%&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;if&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;product&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;%}&lt;/span&gt;
  &lt;span class="cp"&gt;{%&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;if&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;product&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nv"&gt;metafields&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nv"&gt;custom&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;size&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;&amp;gt;&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;%}&lt;/span&gt;
    &lt;span class="cp"&gt;{{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;product&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nv"&gt;metafields&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nv"&gt;custom&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;|&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nf"&gt;json&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;}}&lt;/span&gt;
  &lt;span class="cp"&gt;{%&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;else&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;%}&lt;/span&gt;
    &amp;lt;!-- No custom metafields --&amp;gt;
  &lt;span class="cp"&gt;{%&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;endif&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;%}&lt;/span&gt;
&lt;span class="cp"&gt;{%&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;else&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;%}&lt;/span&gt;
  &amp;lt;!-- Product is nil --&amp;gt;
&lt;span class="cp"&gt;{%&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;endif&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;%}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Step 5: Test expressions incrementally
&lt;/h3&gt;

&lt;p&gt;Break complex expressions into smaller parts:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight liquid"&gt;&lt;code&gt;&amp;lt;!-- Instead of this --&amp;gt;
&lt;span class="cp"&gt;{{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;product&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nv"&gt;metafields&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nv"&gt;custom&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nv"&gt;care_instructions&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nv"&gt;value&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;|&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nf"&gt;newline_to_br&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;}}&lt;/span&gt;

&amp;lt;!-- Test each part --&amp;gt;
&lt;span class="cp"&gt;{{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;product&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nv"&gt;metafields&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;|&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nf"&gt;json&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;}}&lt;/span&gt;
&lt;span class="cp"&gt;{{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;product&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nv"&gt;metafields&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nv"&gt;custom&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;|&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nf"&gt;json&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;}}&lt;/span&gt;
&lt;span class="cp"&gt;{{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;product&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nv"&gt;metafields&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nv"&gt;custom&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nv"&gt;care_instructions&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;|&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nf"&gt;json&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;}}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  Performance Debugging
&lt;/h2&gt;

&lt;p&gt;Some Liquid issues aren't errors — they're performance problems.&lt;/p&gt;

&lt;h3&gt;
  
  
  Too many API calls
&lt;/h3&gt;

&lt;p&gt;Each time you access &lt;code&gt;all_products&lt;/code&gt;, &lt;code&gt;collections&lt;/code&gt;, or similar global objects, Shopify makes API calls. Too many calls slow down your page.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight liquid"&gt;&lt;code&gt;&amp;lt;!-- Bad — N+1 query problem --&amp;gt;
&lt;span class="cp"&gt;{%&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;for&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;product_handle&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;in&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;product_handles&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;%}&lt;/span&gt;
  &lt;span class="cp"&gt;{%&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;assign&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;p&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;all_products&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nv"&gt;product_handle&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;%}&lt;/span&gt;
  &lt;span class="cp"&gt;{{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;p&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nv"&gt;title&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;}}&lt;/span&gt;
&lt;span class="cp"&gt;{%&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;endfor&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;%}&lt;/span&gt;

&amp;lt;!-- Better — use collection or section settings --&amp;gt;
&lt;span class="cp"&gt;{%&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;for&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;product&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;in&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;collection&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nv"&gt;products&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;%}&lt;/span&gt;
  &lt;span class="cp"&gt;{{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;product&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nv"&gt;title&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;}}&lt;/span&gt;
&lt;span class="cp"&gt;{%&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;endfor&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;%}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Heavy JSON output
&lt;/h3&gt;

&lt;p&gt;Outputting large objects as JSON increases page size:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight liquid"&gt;&lt;code&gt;&amp;lt;!-- Bad — includes all product data --&amp;gt;
&lt;span class="cp"&gt;{{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;product&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;|&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nf"&gt;json&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;}}&lt;/span&gt;

&amp;lt;!-- Better — only what you need --&amp;gt;
{
  "id": &lt;span class="cp"&gt;{{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;product&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nv"&gt;id&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;|&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nf"&gt;json&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;}}&lt;/span&gt;,
  "title": &lt;span class="cp"&gt;{{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;product&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nv"&gt;title&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;|&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nf"&gt;json&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;}}&lt;/span&gt;,
  "price": &lt;span class="cp"&gt;{{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;product&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nv"&gt;price&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;|&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nf"&gt;json&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;}}&lt;/span&gt;
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Identify slow sections
&lt;/h3&gt;

&lt;p&gt;Use browser DevTools Network tab to check page load time. If pages are slow:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Check for excessive &lt;code&gt;for&lt;/code&gt; loops&lt;/li&gt;
&lt;li&gt;Look for &lt;code&gt;all_products&lt;/code&gt; or &lt;code&gt;collections&lt;/code&gt; calls&lt;/li&gt;
&lt;li&gt;Reduce JSON payload size&lt;/li&gt;
&lt;li&gt;Consider lazy loading non-critical content&lt;/li&gt;
&lt;/ol&gt;




&lt;h2&gt;
  
  
  Debugging Metafields
&lt;/h2&gt;

&lt;p&gt;Metafields are a common source of confusion because they may or may not exist.&lt;/p&gt;

&lt;h3&gt;
  
  
  Check if a metafield exists
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight liquid"&gt;&lt;code&gt;&lt;span class="cp"&gt;{%&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;if&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;product&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nv"&gt;metafields&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nv"&gt;custom&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nv"&gt;care_instructions&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;%}&lt;/span&gt;
  &lt;span class="cp"&gt;{{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;product&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nv"&gt;metafields&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nv"&gt;custom&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nv"&gt;care_instructions&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nv"&gt;value&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;}}&lt;/span&gt;
&lt;span class="cp"&gt;{%&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;else&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;%}&lt;/span&gt;
  No care instructions available.
&lt;span class="cp"&gt;{%&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;endif&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;%}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  List all metafields
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight liquid"&gt;&lt;code&gt;&amp;lt;pre&amp;gt;&lt;span class="cp"&gt;{{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;product&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nv"&gt;metafields&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;|&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nf"&gt;json&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;}}&lt;/span&gt;&amp;lt;/pre&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Access nested metafield values
&lt;/h3&gt;

&lt;p&gt;For JSON metafields:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight liquid"&gt;&lt;code&gt;&lt;span class="cp"&gt;{%&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;assign&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;data&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;product&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nv"&gt;metafields&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nv"&gt;custom&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nv"&gt;specs&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nv"&gt;value&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;%}&lt;/span&gt;
&lt;span class="cp"&gt;{{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;data&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nv"&gt;weight&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;}}&lt;/span&gt;
&lt;span class="cp"&gt;{{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;data&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nv"&gt;dimensions&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;}}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  Summary
&lt;/h2&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Method&lt;/th&gt;
&lt;th&gt;Best for&lt;/th&gt;
&lt;th&gt;Limitations&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;`\&lt;/td&gt;
&lt;td&gt;json` filter&lt;/td&gt;
&lt;td&gt;Quick data inspection&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Theme Check&lt;/td&gt;
&lt;td&gt;Pre-deploy linting&lt;/td&gt;
&lt;td&gt;Static only, no runtime&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Browser DevTools&lt;/td&gt;
&lt;td&gt;JavaScript debugging&lt;/td&gt;
&lt;td&gt;Can't access Liquid objects&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Page source search&lt;/td&gt;
&lt;td&gt;Finding error messages&lt;/td&gt;
&lt;td&gt;No object inspection&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Shopify Theme Devtools&lt;/td&gt;
&lt;td&gt;Full debugging workflow&lt;/td&gt;
&lt;td&gt;Requires installation&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;For most developers, combining Theme Check (for linting) with an in-browser devtools panel (for runtime debugging) provides the most complete debugging experience.&lt;/p&gt;




&lt;h2&gt;
  
  
  Additional Resources
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://shopify.dev/docs/api/liquid" rel="noopener noreferrer"&gt;Shopify Liquid Reference&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://github.com/Shopify/theme-check" rel="noopener noreferrer"&gt;Theme Check Documentation&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://github.com/yakohere/shopify-theme-devtools" rel="noopener noreferrer"&gt;Shopify Theme Devtools&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://liquidjs.com/" rel="noopener noreferrer"&gt;LiquidJS Documentation&lt;/a&gt; (for understanding filter behavior)&lt;/li&gt;
&lt;/ul&gt;




&lt;p&gt;What debugging techniques do you use for Shopify Liquid? Share your tips in the comments.&lt;/p&gt;




&lt;p&gt;&lt;strong&gt;Tags:&lt;/strong&gt; #shopify #liquid #debugging #webdev #ecommerce #tutorial #devtools&lt;/p&gt;

</description>
      <category>shopfiy</category>
      <category>shopifytheme</category>
      <category>shopifyliquid</category>
    </item>
    <item>
      <title>Shopify Theme Devtools: Debug Liquid Like It's JavaScript</title>
      <dc:creator>Yakhyo Ismoildjonov</dc:creator>
      <pubDate>Sun, 11 Jan 2026 13:01:47 +0000</pubDate>
      <link>https://dev.to/yakohere/stop-consolelog-debugging-your-shopify-themes-theres-a-better-way-of5</link>
      <guid>https://dev.to/yakohere/stop-consolelog-debugging-your-shopify-themes-theres-a-better-way-of5</guid>
      <description>&lt;p&gt;If you've ever spent hours hunting down a &lt;code&gt;Liquid error&lt;/code&gt; buried somewhere in your Shopify theme, or wondered "what the hell is in this &lt;code&gt;product&lt;/code&gt; object right now?", this tool is for you.&lt;/p&gt;

&lt;p&gt;I built &lt;strong&gt;&lt;a href="https://github.com/yakohere/shopify-theme-devtools" rel="noopener noreferrer"&gt;Shopify Theme Devtools&lt;/a&gt;&lt;/strong&gt; — an in-browser developer panel that brings Chrome DevTools-level debugging to Shopify Liquid development. No more &lt;code&gt;{{ product | json }}&lt;/code&gt; scattered throughout your templates. No more refreshing the page to check cart state. No more guessing.&lt;/p&gt;




&lt;h2&gt;
  
  
  The Problem with Shopify Theme Debugging
&lt;/h2&gt;

&lt;p&gt;Shopify's Liquid templating is powerful, but debugging it is painful:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;No native debugger&lt;/strong&gt; — You can't step through Liquid code&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Silent failures&lt;/strong&gt; — Errors often render as empty strings or cryptic messages buried in HTML&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Context blindness&lt;/strong&gt; — You can't easily see what data is available in your current template&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Cart state mystery&lt;/strong&gt; — Testing cart logic requires manually adding/removing items&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Metafield hunting&lt;/strong&gt; — Finding and testing metafield values across resources is tedious&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Most developers resort to sprinkling &lt;code&gt;{{ some_object | json }}&lt;/code&gt; throughout their code, refreshing, copying the output, and pasting into a JSON formatter. Over and over.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;There had to be a better way.&lt;/strong&gt;&lt;/p&gt;




&lt;h2&gt;
  
  
  Introducing Shopify Theme Devtools
&lt;/h2&gt;

&lt;p&gt;Shopify Theme Devtools is a single Liquid snippet that injects a full-featured debugging panel into your development theme. It's like having Chrome DevTools, but specifically designed for Shopify Liquid.&lt;/p&gt;

&lt;h3&gt;
  
  
  Key Features at a Glance
&lt;/h3&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Feature&lt;/th&gt;
&lt;th&gt;What It Does&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Objects Inspector&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Browse all Liquid objects (&lt;code&gt;shop&lt;/code&gt;, &lt;code&gt;product&lt;/code&gt;, &lt;code&gt;cart&lt;/code&gt;, etc.) with search&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Live Console&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Evaluate Liquid expressions in real-time with autocomplete&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Cart Panel&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Manipulate cart state, view history, restore snapshots&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Error Detection&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Automatically finds Liquid errors, Drop leaks, missing assets&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Network Monitor&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Capture and replay Shopify API requests&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Metafields Viewer&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Explore metafields across all resources&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;SEO Inspector&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Validate meta tags, Open Graph, JSON-LD&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;




&lt;h2&gt;
  
  
  Installation: 60 Seconds to Better Debugging
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;npx shopify-theme-devtools init &lt;span class="nt"&gt;--inject&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;That's it. This command:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Copies the bridge snippet to your &lt;code&gt;snippets/&lt;/code&gt; folder&lt;/li&gt;
&lt;li&gt;Automatically adds the render tag to your &lt;code&gt;theme.liquid&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;Detects and injects your &lt;code&gt;metafields.json&lt;/code&gt; schema&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;strong&gt;Or install manually:&lt;/strong&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;npx shopify-theme-devtools init
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Then add this line to &lt;code&gt;layout/theme.liquid&lt;/code&gt; just before &lt;code&gt;&amp;lt;/body&amp;gt;&lt;/code&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight liquid"&gt;&lt;code&gt;&lt;span class="cp"&gt;{%&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;render&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s1"&gt;'theme-devtools-bridge'&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;%}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Security Note
&lt;/h3&gt;

&lt;p&gt;The panel &lt;strong&gt;only renders on unpublished/development themes&lt;/strong&gt;. It checks &lt;code&gt;theme.role != 'main'&lt;/code&gt; before loading, so it's completely safe to commit to your repository. Your production store will never see it.&lt;/p&gt;




&lt;h2&gt;
  
  
  Deep Dive: The Objects Inspector
&lt;/h2&gt;

&lt;p&gt;The Objects Inspector is probably where you'll spend most of your time. It gives you a live, searchable view of every Liquid object available in the current template context.&lt;/p&gt;

&lt;h3&gt;
  
  
  Browsing Objects
&lt;/h3&gt;

&lt;p&gt;Click through the tree to explore nested properties:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;shop
├── name: "My Awesome Store"
├── email: "hello@mystore.com"
├── currency: "USD"
├── metafields
│   └── custom
│       └── announcement_bar: "Free shipping over $50!"
└── ...
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  One-Click Path Copying
&lt;/h3&gt;

&lt;p&gt;Click any property key to copy its Liquid path to your clipboard:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Click &lt;code&gt;title&lt;/code&gt; under &lt;code&gt;product&lt;/code&gt; → copies &lt;code&gt;product.title&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;Click &lt;code&gt;[0]&lt;/code&gt; under &lt;code&gt;variants&lt;/code&gt; → copies &lt;code&gt;product.variants[0]&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;Click &lt;code&gt;price&lt;/code&gt; under that → copies &lt;code&gt;product.variants[0].price&lt;/code&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;No more guessing the correct path syntax.&lt;/p&gt;

&lt;h3&gt;
  
  
  Deep Search
&lt;/h3&gt;

&lt;p&gt;Type in the search box to find properties anywhere in the object tree. Looking for a specific metafield key? Search for it. Need to find where &lt;code&gt;inventory_quantity&lt;/code&gt; lives? Search finds it instantly.&lt;/p&gt;




&lt;h2&gt;
  
  
  Deep Dive: The Liquid Console
&lt;/h2&gt;

&lt;p&gt;This is where Shopify Theme Devtools really shines. The Console panel gives you a live Liquid expression evaluator — think of it as a REPL for Liquid.&lt;/p&gt;

&lt;h3&gt;
  
  
  Basic Usage
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;&amp;gt; product.title
"Classic Cotton T-Shirt"

&amp;gt; product.price | money
"$29.99"

&amp;gt; cart.item_count
3

&amp;gt; shop.name | upcase
"MY AWESOME STORE"
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Supported Liquid Filters
&lt;/h3&gt;

&lt;p&gt;The evaluator supports 50+ Liquid filters, including Shopify-specific ones:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;&amp;gt; product.title | upcase
"CLASSIC COTTON T-SHIRT"

&amp;gt; product.title | downcase | split: ' ' | first
"classic"

&amp;gt; product.price | money_with_currency
"$29.99 USD"

&amp;gt; cart.items | size
3

&amp;gt; product.variants | first | json
{"id": 12345, "title": "Small / Blue", ...}

&amp;gt; product.tags | join: ', '
"cotton, summer, sale"
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Array Navigation
&lt;/h3&gt;

&lt;p&gt;Navigate complex data structures with bracket notation:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;&amp;gt; product.variants[0].title
"Small / Blue"

&amp;gt; product.images[0].src
"https://cdn.shopify.com/..."

&amp;gt; cart.items[0].properties._gift_wrap
"Yes"
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Command History
&lt;/h3&gt;

&lt;p&gt;Use the up/down arrow keys to navigate through previous expressions. Your history persists across page navigations.&lt;/p&gt;

&lt;h3&gt;
  
  
  Autocomplete
&lt;/h3&gt;

&lt;p&gt;Press &lt;code&gt;Tab&lt;/code&gt; to autocomplete object paths as you type. The console knows what properties are available and suggests them.&lt;/p&gt;




&lt;h2&gt;
  
  
  Deep Dive: Liquid Error Detection
&lt;/h2&gt;

&lt;p&gt;One of the most valuable features is automatic error detection. The Console panel continuously scans your page for common Liquid issues.&lt;/p&gt;

&lt;h3&gt;
  
  
  Error Types Detected
&lt;/h3&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Error Type&lt;/th&gt;
&lt;th&gt;Example&lt;/th&gt;
&lt;th&gt;What It Means&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Liquid error&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;&lt;code&gt;Liquid error: undefined method 'size'&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Runtime error in your Liquid code&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Syntax error&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;&lt;code&gt;Liquid syntax error: Unknown tag 'endif'&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Invalid Liquid syntax&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Drop leaks&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;&lt;code&gt;#&amp;lt;ProductDrop:0x00007f...&amp;gt;&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Raw Ruby object rendered (usually from missing `&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Missing snippets&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;{% raw %}&lt;code&gt;Liquid error: Could not find snippet 'missing-file'&lt;/code&gt;
&lt;/td&gt;
&lt;td&gt;Referenced snippet doesn't exist&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Schema errors&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;&lt;code&gt;Liquid error: Invalid JSON in schema&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Malformed JSON in section schema&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;JSON filter errors&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;&lt;code&gt;{"error":"not found"}&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Failed `&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;h3&gt;
  
  
  Smart Fix Suggestions
&lt;/h3&gt;

&lt;p&gt;Each error comes with context-aware suggestions:&lt;br&gt;
{% raw %}&lt;/p&gt;
&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;❌ Liquid error: undefined method 'price' for nil:NilClass
   📍 Found in: sections/product-card.liquid
   💡 Suggestion: Check if 'product' exists before accessing 'price'. 
      Use: {% if product %}{{ product.price }}{% endif %}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;h3&gt;
  
  
  Drop Object Detection
&lt;/h3&gt;

&lt;p&gt;This catches a sneaky bug that's easy to miss. If you accidentally render a Liquid object without the &lt;code&gt;| json&lt;/code&gt; filter:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight liquid"&gt;&lt;code&gt;&amp;lt;!-- Wrong --&amp;gt;
&amp;lt;script&amp;gt;
  const product = &lt;span class="cp"&gt;{{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;product&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;}}&lt;/span&gt;;
&amp;lt;/script&amp;gt;

&amp;lt;!-- Correct --&amp;gt;
&amp;lt;script&amp;gt;
  const product = &lt;span class="cp"&gt;{{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;product&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;|&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nf"&gt;json&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;}}&lt;/span&gt;;
&amp;lt;/script&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The first version renders as &lt;code&gt;#&amp;lt;ProductDrop:0x00007f...&amp;gt;&lt;/code&gt;, breaking your JavaScript. Devtools catches this automatically.&lt;/p&gt;




&lt;h2&gt;
  
  
  Deep Dive: Cart Panel
&lt;/h2&gt;

&lt;p&gt;Testing cart-dependent features (discounts, upsells, shipping calculators) usually means manually adding items, checking state, removing them, repeat. The Cart Panel changes this.&lt;/p&gt;

&lt;h3&gt;
  
  
  Live Cart State
&lt;/h3&gt;

&lt;p&gt;See your current cart state in real-time:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Cart (3 items, $89.97)
├── Classic Cotton T-Shirt (Qty: 2) — $59.98
│   └── properties: { _gift_wrap: "Yes" }
├── Leather Belt (Qty: 1) — $29.99
└── attributes: { note: "Please gift wrap" }
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Quantity Controls
&lt;/h3&gt;

&lt;p&gt;Adjust quantities directly from the panel. Changes reflect immediately in both the panel and your theme.&lt;/p&gt;

&lt;h3&gt;
  
  
  Cart History &amp;amp; Snapshots
&lt;/h3&gt;

&lt;p&gt;Every cart mutation is recorded with a timestamp:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;12:34:52 — Added "Classic Cotton T-Shirt" (Qty: 1)
12:35:10 — Updated "Classic Cotton T-Shirt" (Qty: 1 → 2)
12:35:45 — Added "Leather Belt" (Qty: 1)
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Click any snapshot to restore that exact cart state.&lt;/strong&gt; Testing "empty cart" vs "3 items" vs "10+ items" becomes instant.&lt;/p&gt;

&lt;h3&gt;
  
  
  Cart Scenarios
&lt;/h3&gt;

&lt;p&gt;Save named cart configurations for quick testing:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;"Empty Cart"&lt;/li&gt;
&lt;li&gt;"Single Item"&lt;/li&gt;
&lt;li&gt;"Gift Card Only"&lt;/li&gt;
&lt;li&gt;"Mixed Products + Subscription"&lt;/li&gt;
&lt;li&gt;"Over Free Shipping Threshold"&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;One click to load any scenario.&lt;/p&gt;

&lt;h3&gt;
  
  
  Cart Tests
&lt;/h3&gt;

&lt;p&gt;Create validation rules that run automatically when the cart changes:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="c1"&gt;// Rule: Gift items must have _gwp_source property&lt;/span&gt;
&lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;type&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;property_dependency&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nx"&gt;name&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;GWP Validation&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nx"&gt;condition&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nl"&gt;property&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;_is_gwp&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;value&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;true&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt; &lt;span class="p"&gt;},&lt;/span&gt;
  &lt;span class="nx"&gt;required&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;_gwp_source&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;_gwp_campaign&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="c1"&gt;// Rule: Max 5 of any single item&lt;/span&gt;
&lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="na"&gt;type&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;quantity&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="na"&gt;name&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Per-Item Limit&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="na"&gt;max_per_item&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;5&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;16 pre-built templates cover common scenarios.&lt;/p&gt;




&lt;h2&gt;
  
  
  Deep Dive: Network Panel
&lt;/h2&gt;

&lt;p&gt;The Network Panel captures and lets you inspect all Shopify API requests.&lt;/p&gt;

&lt;h3&gt;
  
  
  Request Logging
&lt;/h3&gt;

&lt;p&gt;Automatically captures:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Cart API (&lt;code&gt;/cart/add.js&lt;/code&gt;, &lt;code&gt;/cart/change.js&lt;/code&gt;, &lt;code&gt;/cart/update.js&lt;/code&gt;)&lt;/li&gt;
&lt;li&gt;Product API (&lt;code&gt;/products/*.json&lt;/code&gt;)&lt;/li&gt;
&lt;li&gt;Collection API (&lt;code&gt;/collections/*.json&lt;/code&gt;)&lt;/li&gt;
&lt;li&gt;Search API (&lt;code&gt;/search/suggest.json&lt;/code&gt;)&lt;/li&gt;
&lt;li&gt;Storefront GraphQL&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Request Details
&lt;/h3&gt;

&lt;p&gt;For each request, see:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Method, URL, status code&lt;/li&gt;
&lt;li&gt;Request headers and body&lt;/li&gt;
&lt;li&gt;Response headers and body&lt;/li&gt;
&lt;li&gt;Timing information&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Edit &amp;amp; Replay
&lt;/h3&gt;

&lt;p&gt;Modify any captured request and resend it:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="c1"&gt;// Original request&lt;/span&gt;
&lt;span class="nx"&gt;POST&lt;/span&gt; &lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="nx"&gt;cart&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="nx"&gt;add&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;js&lt;/span&gt;
&lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;id&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;12345&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;quantity&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;1&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="c1"&gt;// Edit and replay with different quantity&lt;/span&gt;
&lt;span class="nx"&gt;POST&lt;/span&gt; &lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="nx"&gt;cart&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="nx"&gt;add&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;js&lt;/span&gt;
&lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;id&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;12345&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;quantity&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;5&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Cart State Diff
&lt;/h3&gt;

&lt;p&gt;After cart mutations, see exactly what changed:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight diff"&gt;&lt;code&gt;  item_count: 3 → 4
&lt;span class="gi"&gt;+ items[3]: { title: "New Item", quantity: 1 }
&lt;/span&gt;  total_price: 8997 → 11996
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Export Options
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Copy as cURL&lt;/strong&gt; — For terminal debugging&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Copy as Fetch&lt;/strong&gt; — For browser console testing&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  Additional Panels
&lt;/h2&gt;

&lt;h3&gt;
  
  
  Metafields Viewer
&lt;/h3&gt;

&lt;p&gt;Browse metafields across all resources:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;product.metafields
├── custom
│   ├── care_instructions: "Machine wash cold"
│   ├── material: "100% Cotton"
│   └── sustainability_score: 8
└── reviews
    ├── rating: 4.5
    └── count: 127

shop.metafields
└── custom
    └── announcement: "Free shipping over $50!"
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  SEO Inspector
&lt;/h3&gt;

&lt;p&gt;Validate your SEO implementation:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Meta Tags&lt;/strong&gt; — title, description, canonical&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Open Graph&lt;/strong&gt; — og:title, og:image, og:description&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Twitter Cards&lt;/strong&gt; — twitter:card, twitter:title&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;JSON-LD&lt;/strong&gt; — Product, Organization, BreadcrumbList schemas&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Errors are highlighted with fix suggestions.&lt;/p&gt;

&lt;h3&gt;
  
  
  Localization Panel
&lt;/h3&gt;

&lt;p&gt;For multi-market stores:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Current market, currency, language&lt;/li&gt;
&lt;li&gt;Available markets with quick switcher&lt;/li&gt;
&lt;li&gt;Country data and shipping zones&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Analytics Viewer
&lt;/h3&gt;

&lt;p&gt;Detects installed tracking:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Google Analytics (GA4, Universal)&lt;/li&gt;
&lt;li&gt;Facebook Pixel&lt;/li&gt;
&lt;li&gt;TikTok Pixel&lt;/li&gt;
&lt;li&gt;Pinterest Tag&lt;/li&gt;
&lt;li&gt;Custom scripts&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Storage Inspector
&lt;/h3&gt;

&lt;p&gt;Browse and edit:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;localStorage&lt;/li&gt;
&lt;li&gt;sessionStorage
&lt;/li&gt;
&lt;li&gt;Cookies (with expiration and flags)&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  Keyboard Shortcuts
&lt;/h2&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Action&lt;/th&gt;
&lt;th&gt;Mac&lt;/th&gt;
&lt;th&gt;Windows&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Toggle Panel&lt;/td&gt;
&lt;td&gt;&lt;code&gt;Cmd+Shift+D&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;&lt;code&gt;Ctrl+Shift+D&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Evaluate Expression&lt;/td&gt;
&lt;td&gt;&lt;code&gt;Enter&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;&lt;code&gt;Enter&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Autocomplete&lt;/td&gt;
&lt;td&gt;&lt;code&gt;Tab&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;&lt;code&gt;Tab&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Command History&lt;/td&gt;
&lt;td&gt;
&lt;code&gt;↑&lt;/code&gt; / &lt;code&gt;↓&lt;/code&gt;
&lt;/td&gt;
&lt;td&gt;
&lt;code&gt;↑&lt;/code&gt; / &lt;code&gt;↓&lt;/code&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;




&lt;h2&gt;
  
  
  Tab Customization
&lt;/h2&gt;

&lt;p&gt;Like Chrome DevTools, you can customize your layout:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Right-click any tab&lt;/strong&gt; to show/hide it&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Drag tabs&lt;/strong&gt; to reorder them&lt;/li&gt;
&lt;li&gt;Hidden tabs are completely unloaded (saves memory)&lt;/li&gt;
&lt;li&gt;"Reset to Defaults" restores original layout&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  Configuration Options
&lt;/h2&gt;

&lt;h3&gt;
  
  
  Local Development Mode
&lt;/h3&gt;

&lt;p&gt;For development with hot reload:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight liquid"&gt;&lt;code&gt;&lt;span class="cp"&gt;{%-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;assign&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;devtools_local&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="kc"&gt;true&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="cp"&gt;-%}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Then run:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;npm run dev  &lt;span class="c"&gt;# Starts at localhost:9999&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Self-Hosted Assets
&lt;/h3&gt;

&lt;p&gt;If you prefer not to use the CDN:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;npx shopify-theme-devtools init &lt;span class="nt"&gt;--local&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This copies JS/CSS to your &lt;code&gt;assets/&lt;/code&gt; folder.&lt;/p&gt;

&lt;h3&gt;
  
  
  Metafields Schema
&lt;/h3&gt;

&lt;p&gt;To show all defined metafields (not just ones with values), the CLI automatically detects your &lt;code&gt;.shopify/metafields.json&lt;/code&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;npx shopify-theme-devtools &lt;span class="nb"&gt;sync&lt;/span&gt;  &lt;span class="c"&gt;# Update metafields schema&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  How It Works (Technical Details)
&lt;/h2&gt;

&lt;p&gt;For the curious:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Context Extraction&lt;/strong&gt; — The Liquid bridge renders theme objects as a JSON blob using &lt;code&gt;| json&lt;/code&gt; filters&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Async Data Loading&lt;/strong&gt; — Product variants and cart data are fetched via Shopify's JSON APIs for live data&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Expression Evaluation&lt;/strong&gt; — Uses &lt;a href="https://liquidjs.com/" rel="noopener noreferrer"&gt;LiquidJS&lt;/a&gt; to evaluate expressions client-side&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Shadow DOM Isolation&lt;/strong&gt; — All styles are scoped to prevent theme CSS conflicts&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Session Persistence&lt;/strong&gt; — Logs, cart history, and preferences survive page navigations&lt;/li&gt;
&lt;/ol&gt;

&lt;h3&gt;
  
  
  Tech Stack
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;&lt;a href="https://lit.dev/" rel="noopener noreferrer"&gt;Lit&lt;/a&gt;&lt;/strong&gt; — Lightweight Web Components (fast, no virtual DOM)&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;&lt;a href="https://liquidjs.com/" rel="noopener noreferrer"&gt;LiquidJS&lt;/a&gt;&lt;/strong&gt; — Liquid template engine for expression evaluation&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;&lt;a href="https://vitejs.dev/" rel="noopener noreferrer"&gt;Vite&lt;/a&gt;&lt;/strong&gt; — Fast build tooling&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Browser Support
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Chrome 90+&lt;/li&gt;
&lt;li&gt;Firefox 90+&lt;/li&gt;
&lt;li&gt;Safari 14+&lt;/li&gt;
&lt;li&gt;Edge 90+&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  Real-World Use Cases
&lt;/h2&gt;

&lt;h3&gt;
  
  
  Debugging a Broken Product Page
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;&amp;gt; product
null

// Aha! Product object isn't available. Check your template assignment.
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Testing Discount Logic
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;&amp;gt; cart.total_price | money
"$89.97"

&amp;gt; cart.total_discount | money
"$10.00"

&amp;gt; cart.items | map: 'line_level_discount_allocations' | flatten | size
2
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Finding Available Metafields
&lt;/h3&gt;

&lt;p&gt;Search "metafield" in Objects Inspector to see all metafields across every resource, with their current values.&lt;/p&gt;

&lt;h3&gt;
  
  
  Testing Cart Edge Cases
&lt;/h3&gt;

&lt;ol&gt;
&lt;li&gt;Save current cart as "Baseline" scenario&lt;/li&gt;
&lt;li&gt;Clear cart&lt;/li&gt;
&lt;li&gt;Add edge case items (subscription + one-time, quantity limits, etc.)&lt;/li&gt;
&lt;li&gt;Test your theme&lt;/li&gt;
&lt;li&gt;One-click restore to "Baseline"&lt;/li&gt;
&lt;/ol&gt;




&lt;h2&gt;
  
  
  Get Started
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;npx shopify-theme-devtools init &lt;span class="nt"&gt;--inject&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Then press &lt;code&gt;Cmd+Shift+D&lt;/code&gt; (or &lt;code&gt;Ctrl+Shift+D&lt;/code&gt;) to open the panel.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Links:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;📦 &lt;a href="https://www.npmjs.com/package/shopify-theme-devtools" rel="noopener noreferrer"&gt;npm package&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;🐙 &lt;a href="https://github.com/yakohere/shopify-theme-devtools" rel="noopener noreferrer"&gt;GitHub repo&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;📖 &lt;a href="https://github.com/yakohere/shopify-theme-devtools#readme" rel="noopener noreferrer"&gt;Full documentation&lt;/a&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Wrapping Up
&lt;/h2&gt;

&lt;p&gt;If you're building Shopify themes, you deserve better debugging tools than &lt;code&gt;{{ thing | json }}&lt;/code&gt;. Shopify Theme Devtools brings the debugging experience you're used to from other frameworks into the Liquid world.&lt;/p&gt;

&lt;p&gt;Give it a try and let me know what you think. What features would you add? Drop a comment below or open an issue on GitHub.&lt;/p&gt;

&lt;p&gt;Happy debugging! 🛠️&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Tags:&lt;/strong&gt; #shopify #webdev #javascript #opensource #devtools #ecommerce #liquidtemplating #debugging&lt;/p&gt;

</description>
      <category>shopify</category>
      <category>shopifydevtools</category>
      <category>shopifythemedevtools</category>
    </item>
  </channel>
</rss>
