Skip to content

Commit

Permalink
fix: improve compat with ts in node16/bundler mode (#145)
Browse files Browse the repository at this point in the history
when using the newer resolution and module modes of typescript, it could pick up `./lib/scss-syntax.mjs`, which does not have a `.d.ts` file next to it.
added the `"types"` condition to ensure imports to `"postcss-scss"` always get a type, no matter if they are sourced in commonjs or esm.
  • Loading branch information
AviVahl committed Aug 14, 2023
1 parent f540bea commit 1acc7e9
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
"types": "lib/scss-syntax.d.ts",
"exports": {
".": {
"types": "./lib/scss-syntax.d.ts",
"require": "./lib/scss-syntax.js",
"import": "./lib/scss-syntax.mjs"
},
Expand Down

0 comments on commit 1acc7e9

Please sign in to comment.