@sanity/cli 5.4.0 → 5.5.0-next.10

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/lib/index.d.ts +27 -0
  2. package/package.json +7 -7
package/lib/index.d.ts CHANGED
@@ -179,6 +179,33 @@ export declare interface CliConfig {
179
179
  * Configuration for Sanity typegen
180
180
  */
181
181
  typegen?: Partial<TypeGenConfig>
182
+ /**
183
+ * Configuration for schema extraction (`sanity schema extract`)
184
+ */
185
+ schemaExtraction?: {
186
+ /**
187
+ * Output path for the extracted schema file.
188
+ * Defaults to `schema.json` in the working directory.
189
+ */
190
+ path?: string
191
+ /**
192
+ * When true, schema fields marked as required will be non-optional in the output.
193
+ * Defaults to `false`
194
+ */
195
+ enforceRequiredFields?: boolean
196
+ /**
197
+ * Additional glob patterns to watch for schema changes in watch mode.
198
+ * These extend the default patterns:
199
+ * - `sanity.config.{js,jsx,ts,tsx,mjs}`
200
+ * - `schema*\/**\/*.{js,jsx,ts,tsx,mjs}`
201
+ */
202
+ watchPatterns?: string[]
203
+ /**
204
+ * The name of the workspace to generate a schema for. Required if your Sanity project has more than one
205
+ * workspace.
206
+ */
207
+ workspace?: string
208
+ }
182
209
  }
183
210
 
184
211
  declare type CliConfigResult =
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sanity/cli",
3
- "version": "5.4.0",
3
+ "version": "5.5.0-next.10+14a2811254",
4
4
  "description": "Sanity CLI tool for managing Sanity installations, managing plugins, schemas and datasets",
5
5
  "keywords": [
6
6
  "sanity",
@@ -57,7 +57,7 @@
57
57
  "pkg-dir": "^5.0.0",
58
58
  "prettier": "^3.7.4",
59
59
  "semver": "^7.7.2",
60
- "@sanity/codegen": "5.4.0"
60
+ "@sanity/codegen": "5.5.0-next.10+14a2811254"
61
61
  },
62
62
  "devDependencies": {
63
63
  "@rexxars/gitconfiglocal": "^3.0.1",
@@ -111,11 +111,11 @@
111
111
  "vitest": "^4.0.16",
112
112
  "which": "^2.0.2",
113
113
  "xdg-basedir": "^4.0.0",
114
- "@repo/eslint-config": "5.4.0",
115
- "@repo/test-config": "5.4.0",
116
- "@repo/tsconfig": "5.4.0",
117
- "@sanity/types": "5.4.0",
118
- "@repo/package.config": "5.4.0"
114
+ "@repo/package.config": "5.5.0-next.10+14a2811254",
115
+ "@repo/eslint-config": "5.5.0-next.10+14a2811254",
116
+ "@repo/test-config": "5.5.0-next.10+14a2811254",
117
+ "@repo/tsconfig": "5.5.0-next.10+14a2811254",
118
+ "@sanity/types": "5.4.0"
119
119
  },
120
120
  "peerDependencies": {
121
121
  "babel-plugin-react-compiler": "*"