Skip to content

Avoid parser blocking scripts by adding defer or async on this tagtheme-checkParserBlockingScript -- ignores all settings #316

@Seikilos

Description

@Seikilos

Describe the bug

The code <script src="js/chart.js/dist/chart.umd.js"></script>
causes Avoid parser blocking scripts by adding deferorasync on this tagtheme-checkParserBlockingScript
despite having set these things:

{% # theme-check-disable ParserBlockingJavaScript %}

and also in .theme-check.yml

ParserBlockingJavascript:
  enabled: false
  ignore: []

ParserBlockingScriptTag:
  enabled: false
  ignore: []
  

Source

{% # theme-check-disable ParserBlockingJavaScript %}

<script src="js/chart.js/dist/chart.umd.js"></script>

{% # theme-check-enable ParserBlockingJavaScript %}

Expected behaviour
No warning because at least one setting for muting ParserBlockingJavaScript should be honored

Actual behaviour
Avoid parser blocking scripts by adding deferorasync on this tagtheme-checkParserBlockingScript Message pops up in visual studio code
image

Debugging information

  • Windows
  • 22H2
  • VS Code 1.86.2
  • Shopify Liquid Extension Version v2.12

Additional context
Add any other context about the problem here.

Metadata

Metadata

Assignees

No one assigned

    Labels

    BugSomething isn't workingSeverity: 4theme bugs that won't be prioritized in the near futuretheme-check

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions