Skip to content

Commit

Permalink
fix: typescript resolution
Browse files Browse the repository at this point in the history
Move 'types' to be first as per typescript requirements.

In order for `vue/types/...` to correctly resolve without extension with module type 'bundler', 'nodenext' etc the wildcard types needs to specify `./types/*.d.ts`.

Many downstream packages import `vue/types/vue` and `vue/types/options` for ambient module argumentation.
  • Loading branch information
blake-newman committed Mar 30, 2023
1 parent a9ca2d8 commit ab77cee
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions package.json
Expand Up @@ -17,20 +17,20 @@
"packages/compiler-sfc"
],
"exports": {
".": {
".": {,
"types": "./types/index.d.ts",
"import": {
"node": "./dist/vue.runtime.mjs",
"default": "./dist/vue.runtime.esm.js"
},
"require": "./dist/vue.runtime.common.js",
"types": "./types/index.d.ts"
"require": "./dist/vue.runtime.common.js"
},
"./compiler-sfc": {
"import": "./compiler-sfc/index.mjs",
"require": "./compiler-sfc/index.js"
},
"./dist/*": "./dist/*",
"./types/*": "./types/*",
"./types/*": "./types/*.d.ts",
"./package.json": "./package.json"
},
"sideEffects": false,
Expand Down

0 comments on commit ab77cee

Please sign in to comment.