Shopify / theme-check

The Ultimate Shopify Theme Linter
Other
337 stars 95 forks source link

Commented out code should be ignored by default #540

Closed ConduciveMammal closed 2 years ago

ConduciveMammal commented 2 years ago

I'm wondering if code commented out with Liquid code should always be ignored by default?

image

charlespwd commented 2 years ago

It should.

hsdonkin commented 2 years ago

This is actually a feature, since liquid can't handle commented out liquid code with syntax errors 🙃

https://github.com/Shopify/liquid/issues/313

charlespwd commented 2 years ago

Good point. But also this particular case should probably be ignored. Since the image won't appear. I believe SyntaxError would still throw in that case even if we start ignoring offenses in comment tags.