Skip to content

Commit

Permalink
Fix conditional import of prettier-plugin-svelte (#332)
Browse files Browse the repository at this point in the history
  • Loading branch information
rsslldnphy authored Dec 8, 2024
1 parent eece72c commit b769c7c
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -85,10 +85,14 @@ module.exports = {
...htmlParsers.vue,
preprocess: vuePreprocessor,
},
svelte: {
...svelteParsers.parsers.svelte,
preprocess: sveltePreprocessor,
},
...(!!svelteParsers.parsers
? {
svelte: {
...svelteParsers.parsers.svelte,
preprocess: sveltePreprocessor,
},
}
: {}),
},
options,
};

0 comments on commit b769c7c

Please sign in to comment.