Closed wrainbird closed 2 years ago
Oh. So I just found out that we turn off the check (silently) when an expression is used in an render(or include) expression.
Which, I suspect, you do if you have an OS2 theme (since all it takes is one {% render block %}
for this tripwire to be triggered).
I'll flag this as a bug and add it to our backlog as I don't have time to fix it right now.
@charlespwd thanks for responding to this.
The only dynamic snippet I render for OS2 themes is for app blocks, e.g.:
{% when '@app' %}
{% render block %}
I removed that code temporarily and was able to find unused snippets. Thanks!
I have installed Shopify CLI with Theme Check (version 1.10.2) - and am not getting errors for Unused Snippets.
I have been creating Snippets on purpose in the snippets directory that aren't being used - but when I run 'theme check' I am getting no errors:
0 offenses detected, 0 offenses auto-correctable
Am I doing something wrong? I have a
.theme-check.yml
file but it is pretty basic (I am enabling Unused Snippet here just to double check):Let me know if there is any other information I can provide to assist with this.