sveltejs / prettier-plugin-svelte

Format your svelte components using prettier.
MIT License
715 stars 95 forks source link

Prettier's `requirePragma` is not respected #350

Closed andreavaccari closed 1 year ago

andreavaccari commented 1 year ago

Given the file test.svelte:

<script>
  const foo =        "bar";
</script>

{foo}

Prettier won't ignore the file even though the pragma is not present:

$ npx prettier --require-pragma --check test.svelte 
    [warn] test.svelte
    [warn] Code style issues found in the above file. Forgot to run Prettier?

See also: https://prettier.io/docs/en/options.html#require-pragma

andreavaccari commented 1 year ago

Thank you for fixing this, @dummdidumm