Skip to content

Commit e7c1f47

Browse files
committed
fix: add /studio export
1 parent 8c8c633 commit e7c1f47

File tree

2 files changed

+17
-40
lines changed

2 files changed

+17
-40
lines changed

package-lock.json

+3-38
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

+14-2
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,20 @@
2626
"require": "./dist/index.js",
2727
"default": "./dist/next-sanity.esm.js"
2828
},
29-
"./package.json": "./package.json"
29+
"./package.json": "./package.json",
30+
"./studio": {
31+
"source": "./src/studio.ts",
32+
"require": "./lib/cjs/studio.js",
33+
"default": "./lib/esm/studio.js"
34+
}
35+
},
36+
"//": "the typesVersion config below is a workaround for TypeScript's lack of support for package exports",
37+
"typesVersions": {
38+
"*": {
39+
"studio": [
40+
"./dist/studio.d.ts"
41+
]
42+
}
3043
},
3144
"main": "dist/index.js",
3245
"module": "dist/next-sanity.esm.js",
@@ -65,7 +78,6 @@
6578
"devDependencies": {
6679
"@async-fn/jest": "^1.5.3",
6780
"@sanity/eslint-config-studio": "^2.0.0",
68-
"@semantic-release/exec": "^6.0.3",
6981
"@testing-library/react-hooks": "^7.0.2",
7082
"@types/eventsource": "^1.1.9",
7183
"@types/jest": "^28.1.6",

0 commit comments

Comments
 (0)