Skip to content

Commit

Permalink
feat: support postcss (#600)
Browse files Browse the repository at this point in the history
  • Loading branch information
baseballyama authored Dec 1, 2024
1 parent 10a218c commit 5586809
Show file tree
Hide file tree
Showing 10 changed files with 1,050 additions and 0 deletions.
5 changes: 5 additions & 0 deletions .changeset/silver-swans-build.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"svelte-eslint-parser": patch
---

feat: support postcss
1 change: 1 addition & 0 deletions src/parser/style-context.ts
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ export function parseStyleContext(
let parseFn: Parser<Root>, sourceAst: Root;
switch (sourceLang) {
case "css":
case "postcss":
parseFn = postcss.parse;
break;
case "scss":
Expand Down
6 changes: 6 additions & 0 deletions tests/fixtures/parser/ast/postcss-input.svelte
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
<style lang="postcss">
body {
colour: white;
background-colour: grey;
}
</style>
Loading

0 comments on commit 5586809

Please sign in to comment.