fix(api): add type definitions to package.json exports (#9486)

This commit is contained in:
André Kohn 2024-04-22 16:18:00 +02:00 committed by GitHub
parent aaa332c6e7
commit be7eab209c
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 10 additions and 2 deletions

View File

@ -0,0 +1,5 @@
---
"@tauri-apps/api": patch:bug
---
Set the `exports > types` package.json field.

View File

@ -21,14 +21,17 @@
"type": "module",
"main": "./index.cjs",
"module": "./index.js",
"types": "./index.d.ts",
"exports": {
".": {
"import": "./index.js",
"require": "./index.cjs"
"require": "./index.cjs",
"types": "./index.d.ts"
},
"./*": {
"import": "./*.js",
"require": "./*.cjs"
"require": "./*.cjs",
"types": "./*.d.ts"
},
"./package.json": "./package.json"
},