Skip to content
This repository has been archived by the owner on Jul 27, 2024. It is now read-only.

schema tag incorrectly reporting as unclosed whilst using whitespace delimiters #637

Closed
ConduciveMammal opened this issue Sep 8, 2022 · 2 comments
Labels
bug Something isn't working

Comments

@ConduciveMammal
Copy link

ConduciveMammal commented Sep 8, 2022

Describe the bug

When using whitespace delimiters on a section's schema tags, theme-check reports it as unclosed.
If I remove these, the error message goes away.

With whitespace delimiter
CleanShot 2022-09-08 at 3 56 37

Without whitespace delimiter
CleanShot 2022-09-08 at 3 57 10

Schema sample:

{%- schema %}
{
  "name": "Blog post header",
  "class": "shopify-section--blog-post-banner",
  "settings": [
    {
      "type": "checkbox",
      "id": "show_category",
      "label": "Show category",
      "info": "The first article's tag will be shown as category.",
      "default": true
    },
    {
      "type": "color",
      "id": "blog_header_background",
      "label": "Background",
      "default": "#f5f5f5"
    },
    {
      "type": "color",
      "id": "blog_header_text_color",
      "label": "Text color",
      "default": "#282828"
    }
  ]
}
{%- endschema -%}

Debugging information

  • OS macOS 12.5.1
  • Version 1.11.0

#637 (comment)

@ConduciveMammal ConduciveMammal added the bug Something isn't working label Sep 8, 2022
@charlespwd
Copy link
Contributor

Upstream Liquid bug, that tag doesn't support whitespace stripping IIRC.

@lukeh-shopify
Copy link
Contributor

👋🏻 Hi @ConduciveMammal! Thanks for reporting this. Unfortunately the Ruby version of theme check has been deprecated for some time. Would you be able to confirm you are still having issues when using our maintained version of theme check? This is done using either the latest version of the Shopify CLI, or via the Shopify Liquid Visual Studio Code extension.

If you are still having issues, please raise an issue over in the CLI or theme tools repositories. Thanks!

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants