docs/checks/space_inside_braces.md in theme-check-0.8.1 vs docs/checks/space_inside_braces.md in theme-check-0.8.2

- old
+ new

@@ -19,10 +19,14 @@ {% endform %} <!-- Arround filter pipelines --> {{ url | asset_url | img_tag }} {% assign my_upcase_string = "Hello world"| upcase %} + +<!-- Arround symbol operators --> +{%- if target == product and product.price_varies -%} +{%- if product.featured_media.width >=165 -%} ``` :+1: Examples of **correct** code for this check: ```liquid @@ -37,18 +41,36 @@ media_size: section.settings.product_recommendations_image_ratio, center_align_text: section.settings.center_align_text %} {{ url | asset_url | img_tag }} {% assign my_upcase_string = "Hello world" | upcase %} +{%- if target == product and product.price_varies -%} +{%- if product.featured_media.width >= 165 -%} ``` ## Check Options The default configuration for this check is the following: ```yaml SpaceInsideBraces: enabled: true +``` + +## Auto-correction + +This check can automatically trim or add spaces around `{{ ... }}`. + +```liquid +{{ x}} +{{x}} +{{ x }} +``` + +Can all be auto-corrected with the `--auto-correct` option to: + +```liquid +{{ x }} ``` ## When Not To Use It If you don't care about the look of your code.