@scalar/workspace-store 0.63.0 → 0.65.0

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 (118) hide show
  1. package/CHANGELOG.md +110 -0
  2. package/README.md +123 -0
  3. package/dist/client.d.ts +28 -0
  4. package/dist/client.d.ts.map +1 -1
  5. package/dist/client.js +320 -144
  6. package/dist/entities/auth/schema.d.ts +236 -0
  7. package/dist/entities/auth/schema.d.ts.map +1 -1
  8. package/dist/entities/auth/schema.js +3 -1
  9. package/dist/helpers/chunk-index.d.ts +113 -0
  10. package/dist/helpers/chunk-index.d.ts.map +1 -0
  11. package/dist/helpers/chunk-index.js +152 -0
  12. package/dist/helpers/external-examples.d.ts +19 -0
  13. package/dist/helpers/external-examples.d.ts.map +1 -0
  14. package/dist/helpers/external-examples.js +51 -0
  15. package/dist/helpers/for-each-path-item-operation.js +4 -4
  16. package/dist/helpers/get-example-value.d.ts +15 -0
  17. package/dist/helpers/get-example-value.d.ts.map +1 -0
  18. package/dist/helpers/get-example-value.js +28 -0
  19. package/dist/helpers/get-resolved-ref.d.ts.map +1 -1
  20. package/dist/helpers/get-resolved-ref.js +12 -1
  21. package/dist/helpers/normalize-boolean-schemas.d.ts +10 -0
  22. package/dist/helpers/normalize-boolean-schemas.d.ts.map +1 -0
  23. package/dist/helpers/normalize-boolean-schemas.js +193 -0
  24. package/dist/helpers/operation-examples.d.ts +6 -0
  25. package/dist/helpers/operation-examples.d.ts.map +1 -0
  26. package/dist/helpers/operation-examples.js +48 -0
  27. package/dist/helpers/serialize-stream-example.d.ts +8 -0
  28. package/dist/helpers/serialize-stream-example.d.ts.map +1 -0
  29. package/dist/helpers/serialize-stream-example.js +52 -0
  30. package/dist/helpers/use-external-examples.d.ts +15 -0
  31. package/dist/helpers/use-external-examples.d.ts.map +1 -0
  32. package/dist/helpers/use-external-examples.js +62 -0
  33. package/dist/mutators/index.d.ts +3 -3
  34. package/dist/mutators/operation/body.d.ts.map +1 -1
  35. package/dist/mutators/operation/body.js +9 -2
  36. package/dist/mutators/operation/parameters.d.ts.map +1 -1
  37. package/dist/mutators/operation/parameters.js +28 -9
  38. package/dist/plugins/bundler/index.d.ts +6 -2
  39. package/dist/plugins/bundler/index.d.ts.map +1 -1
  40. package/dist/plugins/bundler/index.js +20 -4
  41. package/dist/plugins/bundler/openapi-document.d.ts +6 -0
  42. package/dist/plugins/bundler/openapi-document.d.ts.map +1 -0
  43. package/dist/plugins/bundler/openapi-document.js +57 -0
  44. package/dist/request-example/builder/body/build-multipart.d.ts +29 -0
  45. package/dist/request-example/builder/body/build-multipart.d.ts.map +1 -0
  46. package/dist/request-example/builder/body/build-multipart.js +191 -0
  47. package/dist/request-example/builder/body/build-request-body.d.ts +6 -1
  48. package/dist/request-example/builder/body/build-request-body.d.ts.map +1 -1
  49. package/dist/request-example/builder/body/build-request-body.js +80 -23
  50. package/dist/request-example/builder/body/encode-multipart-body.d.ts +8 -8
  51. package/dist/request-example/builder/body/encode-multipart-body.d.ts.map +1 -1
  52. package/dist/request-example/builder/body/encode-multipart-body.js +56 -18
  53. package/dist/request-example/builder/body/get-request-body-example.d.ts.map +1 -1
  54. package/dist/request-example/builder/body/get-request-body-example.js +20 -6
  55. package/dist/request-example/builder/body/multipart-limits.d.ts +3 -0
  56. package/dist/request-example/builder/body/multipart-limits.d.ts.map +1 -0
  57. package/dist/request-example/builder/body/multipart-limits.js +2 -0
  58. package/dist/request-example/builder/body/serialize-form-property.d.ts +2 -0
  59. package/dist/request-example/builder/body/serialize-form-property.d.ts.map +1 -1
  60. package/dist/request-example/builder/body/serialize-form-property.js +3 -2
  61. package/dist/request-example/builder/body/serialize-multipart-array.d.ts +1 -1
  62. package/dist/request-example/builder/build-request.js +5 -0
  63. package/dist/request-example/builder/header/build-request-parameters.d.ts.map +1 -1
  64. package/dist/request-example/builder/header/build-request-parameters.js +5 -1
  65. package/dist/request-example/builder/header/is-param-disabled.d.ts +2 -2
  66. package/dist/request-example/builder/header/is-param-disabled.d.ts.map +1 -1
  67. package/dist/request-example/builder/header/is-param-disabled.js +5 -4
  68. package/dist/request-example/builder/header/serialize-parameter.d.ts +11 -0
  69. package/dist/request-example/builder/header/serialize-parameter.d.ts.map +1 -1
  70. package/dist/request-example/builder/header/serialize-parameter.js +22 -0
  71. package/dist/request-example/builder/helpers/get-example-from-schema.d.ts.map +1 -1
  72. package/dist/request-example/builder/helpers/get-example-from-schema.js +42 -3
  73. package/dist/request-example/builder/helpers/get-example.d.ts +2 -0
  74. package/dist/request-example/builder/helpers/get-example.d.ts.map +1 -1
  75. package/dist/request-example/builder/helpers/get-example.js +14 -9
  76. package/dist/request-example/builder/index.d.ts +2 -2
  77. package/dist/request-example/builder/index.d.ts.map +1 -1
  78. package/dist/request-example/builder/index.js +1 -1
  79. package/dist/request-example/builder/security/secret-types.d.ts +4 -1
  80. package/dist/request-example/builder/security/secret-types.d.ts.map +1 -1
  81. package/dist/request-example/context/headers.d.ts.map +1 -1
  82. package/dist/request-example/context/headers.js +3 -4
  83. package/dist/request-example/context/security/extract-security-scheme-secrets.d.ts.map +1 -1
  84. package/dist/request-example/context/security/extract-security-scheme-secrets.js +15 -0
  85. package/dist/request-example/index.d.ts +5 -2
  86. package/dist/request-example/index.d.ts.map +1 -1
  87. package/dist/request-example/index.js +4 -1
  88. package/dist/request-example/xml/serialize-xml-part.d.ts +9 -0
  89. package/dist/request-example/xml/serialize-xml-part.d.ts.map +1 -0
  90. package/dist/request-example/xml/serialize-xml-part.js +12 -0
  91. package/dist/schemas/extensions.d.ts +9 -0
  92. package/dist/schemas/extensions.d.ts.map +1 -1
  93. package/dist/schemas/extensions.js +9 -0
  94. package/dist/schemas/reference-config/index.d.ts +1 -0
  95. package/dist/schemas/reference-config/index.d.ts.map +1 -1
  96. package/dist/schemas/reference-config/settings.d.ts +1 -0
  97. package/dist/schemas/reference-config/settings.d.ts.map +1 -1
  98. package/dist/schemas/v3.1/strict/oauthflows.d.ts +26 -0
  99. package/dist/schemas/v3.1/strict/oauthflows.d.ts.map +1 -1
  100. package/dist/schemas/v3.1/strict/oauthflows.js +3 -0
  101. package/dist/schemas/v3.1/strict/openapi-document.d.ts +812 -7
  102. package/dist/schemas/v3.1/strict/openapi-document.d.ts.map +1 -1
  103. package/dist/schemas/v3.2/openapi/index.d.ts +5 -0
  104. package/dist/schemas/v3.2/openapi/index.d.ts.map +1 -1
  105. package/dist/schemas/v3.2/openapi/index.js +46 -12
  106. package/dist/schemas/v3.2/strict/openapi-document.d.ts +37 -0
  107. package/dist/schemas/v3.2/strict/openapi-document.d.ts.map +1 -1
  108. package/dist/schemas/v3.2/strict/openapi-document.js +8 -0
  109. package/dist/server.d.ts +21 -1
  110. package/dist/server.d.ts.map +1 -1
  111. package/dist/server.js +60 -34
  112. package/package.json +19 -9
  113. package/dist/schemas/v3.1/openapi/index.d.ts +0 -149
  114. package/dist/schemas/v3.1/openapi/index.d.ts.map +0 -1
  115. package/dist/schemas/v3.1/openapi/index.js +0 -732
  116. package/dist/schemas/v3.1/openapi/reference.d.ts +0 -4
  117. package/dist/schemas/v3.1/openapi/reference.d.ts.map +0 -1
  118. package/dist/schemas/v3.1/openapi/reference.js +0 -29
package/CHANGELOG.md CHANGED
@@ -1,5 +1,115 @@
1
1
  # @scalar/workspace-store
2
2
 
3
+ ## 0.65.0
4
+
5
+ ### Minor Changes
6
+
7
+ - [#10177](https://github.com/scalar/scalar/pull/10177): Use OpenAPI 3.2 schemas throughout workspace-store consumers, stories, tests, and type generation. Update the app editor to offer OpenAPI 3.2 validation and completion while continuing to accept existing 3.1 documents.
8
+
9
+ Preserve OpenAPI 3.2 fields in the loose workspace schema, including tag hierarchy, streaming media types, nested encoding, additional operations, and OAuth device authorization.
10
+
11
+ The editor intentionally offers the 3.2 field set to documents declaring 3.1 as well; it does not flag 3.2-only fields solely because the declared version is 3.1. This does not certify conformance to the declared version or automatically update it. Before using 3.2-only fields, migrate and explicitly declare OpenAPI 3.2, and verify support in other validators and generators. Remove the unused 3.1 loose-schema generator to prevent schema drift.
12
+
13
+ Migration: the OpenAPI 3.1 loose-schema generator (`@scalar/workspace-store/schemas/v3.1/openapi`, published through the wildcard as `@scalar/workspace-store/schemas/v3.1/openapi/index`) and its `@scalar/workspace-store/schemas/v3.1/openapi/reference` helpers have been removed. Import the generator from `@scalar/workspace-store/schemas/v3.2/openapi/index` and the reference helpers from `@scalar/workspace-store/schemas/v3.2/openapi/reference` instead. The `./schemas/*` wildcard and the 3.1 strict-schema exports remain available; the explicit 3.2 strict-schema exports are additive. Locally generated types now use the `OpenAPIV3_2` namespace instead of `OpenAPIV3_1`.
14
+
15
+ Inline the editor path-extension reference so Monaco retains the leading-slash path pattern and does not report valid paths as unknown properties.
16
+
17
+ Document ingestion continues to upgrade only to OpenAPI 3.1, so existing inline XML bodies without `xml.name` remain loadable. This schema migration does not opt consumers into the stricter OpenAPI 3.2 XML upgrade.
18
+
19
+ - [#10191](https://github.com/scalar/scalar/pull/10191): Support OpenAPI 3.2 OAuth device authorization with verification codes, cancellable token polling, stored credentials, and OAuth metadata discovery. Add mock device authorization and approval endpoints with pending, denial, expiry, and polling backoff responses.
20
+
21
+ Use consistent form-encoded Basic credentials and environment substitution across OAuth token and refresh flows. Allow HTTP metadata and verification links on local development hosts and reserved test domains, coerce discovery fields consistently, and report device-code expiry clearly.
22
+
23
+ - [#10208](https://github.com/scalar/scalar/pull/10208): Share OpenAPI 3.2 example-value selection across request bodies, response examples, and code snippets. Preserve serialized payloads verbatim, serialize structured JSON strings correctly, retain falsy values, and replace original example sources after body edits. Keep dataValue and serializedValue during document ingestion.
24
+
25
+ Editing a request body, including form fields, discards its authored `externalValue` URL and replaces it with the edited inline value in the workspace and exported API description. Rendering or focusing a form field preserves the external source.
26
+
27
+ Form editors prefer structured `dataValue` when both example fields exist, while raw editors, requests, and code snippets preserve `serializedValue` as wire text. Structured examples now affect generated request payloads and snippets; XML remains raw-only in the request editor.
28
+
29
+ - [#10178](https://github.com/scalar/scalar/pull/10178): Support OpenAPI 3.2 streaming item schemas in the workspace store, request body examples, and API reference schema views. Frame generated and structured examples as JSON Lines, JSON Sequence, or server-sent events while preserving explicit wire-format strings.
30
+
31
+ Preserve generated falsy request examples (`0`, `false`, and empty strings) for non-streaming bodies as well.
32
+
33
+ Use cURL `--data-binary` for supported streaming media types, making framed body handling explicit. Authored arrays and objects are framed as stream records; authored wire-format strings remain unchanged. SSE records with no valid fields are safely omitted with one console warning per serialization call reporting the omitted count, including when all records are omitted.
34
+
35
+ ### Patch Changes
36
+
37
+ - [#10298](https://github.com/scalar/scalar/pull/10298): Keep the navigation header inline in a compact document, so `x-scalar-navigation.name`, `title` and the other fields stay readable by plain property access and auth, history and the client modal keep working. Only the children travel in the navigation chunk, and `resolve(['x-scalar-navigation'])` loads them onto the document in place. This replaces the 0.64.0 compact wire form, which sent the whole navigation as a chunk reference.
38
+
39
+ Keep pending navigation loads separate when a workspace is reloaded or a document is replaced, so the current document receives its children and stale requests do not publish changes.
40
+
41
+ - [#10251](https://github.com/scalar/scalar/pull/10251): Preserve chained path-item references with non-enumerable links.
42
+
43
+ Remove the HTML output APIs `createHtmlFromOpenApi` and `renderer.renderHtml` from `@scalar/openapi-to-markdown`. Use `createMarkdownFromOpenApi` or `renderer.render` and convert the resulting Markdown with an application-provided renderer when HTML is needed.
44
+
45
+ - [#10203](https://github.com/scalar/scalar/pull/10203): Add a picker for generated response examples with anyOf or oneOf schema variants.
46
+
47
+ Apply union selections to primitive and array examples in the shared generator without reusing the selection for nested unions.
48
+
49
+ The shared generator change also affects request examples, snippets, mock responses, and AsyncAPI payloads: root primitive/array unions now generate their chosen branch before type inference from sibling properties or items. For example, a string schema with `oneOf: [{ const: "first" }, { const: "second" }]` now generates `"first"` by default, and selecting the second branch generates `"second"`. Keywords for unrelated types do not force object/array generation. Root selections are consumed once; nested unions retain their own default or path-specific choice.
50
+
51
+ Do not show a response variant picker for an empty enum, which permits no valid alternatives.
52
+
53
+ Preserve the generated branch shape in mock HTTP responses instead of re-wrapping selected primitive values as arrays based on root sibling `items`. Explicit authored examples retain the existing array normalization.
54
+
55
+ - [#10201](https://github.com/scalar/scalar/pull/10201): Support positional and nested multipart request encoding with prefixEncoding, itemEncoding, and nested encoding objects. Keep generated code snippets in sync with multipart request bodies.
56
+
57
+ Reject ambiguous named positional items and multipart nesting beyond eight levels. Use a stable fallback root for XML parts.
58
+
59
+ Document multipart content-type defaults and wildcard selection policies. Route structured XML parts through a shared adapter while retaining legacy root-name behavior.
60
+
61
+ Regenerate multipart boundaries that collide with resolved text or nested delimiters, keeping binary payload bytes intact.
62
+
63
+ - [#10272](https://github.com/scalar/scalar/pull/10272): Preserve components named `__proto__` when generating sparse server documents.
64
+ - [#10303](https://github.com/scalar/scalar/pull/10303): Preserve parameter edits when another parameter changes, including parameters displaying downloaded examples. Keep downloaded values out of the document until explicitly edited, and use examples and defaults from resolved schema references when building requests.
65
+ - [#10172](https://github.com/scalar/scalar/pull/10172): Preserve boolean schema semantics during client and server ingestion by normalizing true and false schemas to equivalent object schemas before coercion. Keep boolean examples, annotations, and additionalProperties values unchanged.
66
+
67
+ Server normalization now copies only changed schema containers and their ancestors, preserving caller-owned values and sharing unchanged bundled data. Iterative normalization supports deep schema graphs without adding a recursive clone at server ingestion. Opaque example/default/enum/const values remain literal, including in external resources named like OpenAPI map fields.
68
+
69
+ Internal schema markers remain available through backing-data APIs such as `getRaw`, but are omitted from public proxy serialization, rendered schema fields, and saved JSON/YAML API-description exports.
70
+
71
+ After saving, normalized schema positions export `true` as `{}` and `false` as `{ not: {} }`. Validation semantics are unchanged, but the saved representation can differ from the authored text. Boolean `additionalProperties` stays literal `true` or `false`, including after saving and exporting. Original, unsaved exports retain their authored boolean schemas. JSON and YAML exports share the existing save/edit cleanup boundary for internal markers.
72
+
73
+ - [#10198](https://github.com/scalar/scalar/pull/10198): Support OpenAPI 3.2 cookie serialization with semicolon-separated entries and no percent-encoding in requests and code examples.
74
+
75
+ Browser XHR and jQuery code examples now set explicit Cookie header values through `document.cookie` and enable credentialed requests, including when no structured HAR cookies are supplied. Run the cookie setup on the request origin. Requests without cookie-style parameters retain structured HAR cookies alongside explicit Cookie headers.
76
+
77
+ Warn once per parameter name in the developer console when cookie-style parameters declare invalid `explode: false`, then use the expanded fallback consistently for requests and snippets. Browser cookie setup cannot assign cookies to an unrelated API domain; credentialed cross-origin responses require the appropriate CORS configuration and eligible stored cookies.
78
+
79
+ - [#10206](https://github.com/scalar/scalar/pull/10206): Add generic document identity hooks for bundling and an explicit root URI option for reference proxies. Honor OpenAPI 3.2 `$self` through an OpenAPI plugin in workspace-store, including external documents and partial bundles, and enable it in OpenAPI bundling callers.
80
+
81
+ URI resolution now honors root-relative and protocol-relative URLs, query/fragment references, and trailing-slash directory bases for all bundler consumers. Absolute non-HTTP identifiers remain unchanged instead of becoming filesystem paths; loader support is unchanged. Relative HTTP references retain query strings and fragments and are emitted only when they round-trip to the original URL.
82
+
83
+ Preserve authored reference spellings through serialized partial bundles and editable exports, while keeping older OpenAPI resolution and configured loader restrictions unchanged.
84
+
85
+ Keep references matching authored root schema identifiers intact so schema labels and anchors retain their existing behavior.
86
+
87
+ - [#10279](https://github.com/scalar/scalar/pull/10279): Write workspace chunks to the requested absolute output directory, including Windows drives and network shares.
88
+
89
+ ## 0.64.0
90
+
91
+ ### Minor Changes
92
+
93
+ - [#10264](https://github.com/scalar/scalar/pull/10264): Add a `compact` option to the server workspace store, which shrinks the sparse document the browser downloads before it can render anything: Cloudflare's public API goes from 4,447 KB to 431 KB (346 KB to 63 KB gzipped). The navigation becomes one more lazily resolved chunk, and the per-node chunk references become one `x-scalar-chunk-index` extension the client expands back into the very same references as it ingests the document. Defaults are unchanged, and what the client holds in memory is identical either way.
94
+ - [#10240](https://github.com/scalar/scalar/pull/10240): Load external examples on demand when their selected preview is visible or Test Request opens, instead of downloading every payload while loading the API description. Share and cache downloads, preserve relative URL origins, and show loading and retry states while preventing incomplete requests from being sent.
95
+ - [#10263](https://github.com/scalar/scalar/pull/10263): feat: add a `reactive: false` option to the client workspace store, which keeps the whole store API on plain objects for read-mostly consumers such as a server render
96
+
97
+ ### Patch Changes
98
+
99
+ - [#10268](https://github.com/scalar/scalar/pull/10268): Save content-based parameter edits in the media type's examples so enabled JSON query parameters are included in requests. Preserve previously saved edits and migrate them when the parameter is edited again.
100
+ - [#10255](https://github.com/scalar/scalar/pull/10255): fix(api-client): auto-enable optional header/query/cookie rows that have a pre-populated value
101
+
102
+ Optional parameters (headers, query params, cookies) start disabled by default. When the API
103
+ description provides a default or enum value for such a parameter (e.g. `x-scenario-id` with an enum),
104
+ the row was rendered with its checkbox unchecked even though a value was already selected — so the
105
+ parameter was silently dropped from every request until the user manually checked it.
106
+
107
+ The fix auto-enables any row that is only disabled by default (no explicit `x-disabled: true`) and
108
+ already carries a non-empty value, mirroring the existing behaviour when a user types a value into
109
+ a previously-empty row.
110
+
111
+ Use the same enablement rules for the parameter editor, outgoing requests, and generated code snippets.
112
+
3
113
  ## 0.63.0
4
114
 
5
115
  ### Minor Changes
package/README.md CHANGED
@@ -194,6 +194,77 @@ console.log(store.getWorkspace().documents.remoteFile)
194
194
  console.log(store.getWorkspace().documents.fsFile)
195
195
  ```
196
196
 
197
+ ### Compact sparse documents
198
+
199
+ The sparse document is what the browser has to download before it can render anything, and for a
200
+ very large API it grows into a cost of its own: for Cloudflare's public API (3,540 operations, 6,775
201
+ schemas) it is 4,447 KB, of which 2,937 KB is the navigation tree and 1,492 KB is the per-node chunk
202
+ references.
203
+
204
+ `compact: true` changes how that document is spelled on the wire, and nothing else:
205
+
206
+ - `x-scalar-navigation` keeps its document entry — `name`, `title`, `icon` and the rest — and leaves
207
+ only its children in a chunk, written to `chunks/<document>/navigation.json` in `static` mode and
208
+ served by `get('#/<document>/navigation')` in `ssr` mode. `children` is an empty array until
209
+ `store.resolve(['x-scalar-navigation'])` loads them onto the document in place, and
210
+ `x-scalar-navigation-chunk` says where they are until it does. The navigation is never a reference,
211
+ so every reader takes it by plain property access whether or not the document was sent compact.
212
+ - The per-node references under `components` and `paths` are replaced by one `x-scalar-chunk-index`
213
+ extension listing what exists, plus a template per kind saying how a reference to it is spelled.
214
+ The two sections are omitted; anything in them that was never externalized (a path item's
215
+ `parameters`, `summary`, `servers` or extensions) rides along in the index.
216
+
217
+ ```ts
218
+ const store = await createServerWorkspaceStore({
219
+ mode: 'static',
220
+ directory: 'assets',
221
+ compact: true,
222
+ documents: [{ name: 'petstore', document }],
223
+ })
224
+ ```
225
+
226
+ ```jsonc
227
+ {
228
+ "openapi": "3.1.0",
229
+ "info": { "title": "Petstore", "version": "1.0.0" },
230
+ "x-scalar-navigation": {
231
+ "id": "petstore",
232
+ "type": "document",
233
+ "title": "Petstore",
234
+ "name": "petstore",
235
+ "children": []
236
+ },
237
+ "x-scalar-navigation-chunk": "./chunks/petstore/navigation.json#",
238
+ "x-scalar-chunk-index": {
239
+ "mode": "static",
240
+ "refs": {
241
+ "components": "./chunks/petstore/components/{type}/{name}.json#",
242
+ "operations": "./chunks/petstore/operations/{path}/{method}.json#"
243
+ },
244
+ "components": { "schemas": ["Pet", "Error"] },
245
+ // `0` marks an operation that was externalized; every other key is kept as it was
246
+ "paths": { "/pets": { "summary": "Pets", "get": 0, "post": 0 } }
247
+ }
248
+ }
249
+ ```
250
+
251
+ The client store expands the index back into the same references as it ingests the document — through
252
+ `addDocument`, `importWorkspaceFromSpecification`, `replaceDocument`, `revertDocumentChanges` or
253
+ `loadWorkspace` — and drops the extension, so what it holds in memory is exactly what a non-compact
254
+ server store would have produced, with the unloaded navigation children the one difference.
255
+ `resolve()`, the bundler and anything enumerating `paths` or `components` see the shape they always
256
+ have. The navigation chunk is loaded once: concurrent resolves share the request, a later one makes
257
+ none, and a workspace exported before the children were loaded can still load them after
258
+ `loadWorkspace` puts it in another store.
259
+
260
+ `getResolvedDocument()` is unaffected and still carries the whole document and its navigation, and so
261
+ are AsyncAPI documents, which are never externalized.
262
+
263
+ | Document | sparse | compact | sparse, gzip | compact, gzip |
264
+ | --- | --- | --- | --- | --- |
265
+ | Cloudflare public API | 4,447 KB | 431 KB | 346 KB | 63 KB |
266
+ | 100 operations over 150 shared schemas | 71 KB | 10 KB | 6 KB | 2 KB |
267
+
197
268
  ## Client-Side Workspace Store
198
269
 
199
270
  A reactive workspace store for managing OpenAPI documents with automatic reference resolution and chunked loading capabilities. Works seamlessly with server-side stores to handle large documents efficiently.
@@ -267,6 +338,33 @@ await store.addDocument({
267
338
  console.log(store.workspace.documents.default)
268
339
  ```
269
340
 
341
+ #### Non-reactive mode
342
+
343
+ By default the workspace is wrapped in Vue's `reactive` and in a change-detection proxy, so a write re-runs Vue effects and is broadcast to every registered plugin. A read-mostly consumer pays for both on every property read and gets nothing back for it — a server render, for example, walks one document across thousands of pages, mutates nothing and observes nothing.
344
+
345
+ Pass `reactive: false` to get the same store API on plain objects:
346
+
347
+ ```ts
348
+ const store = createWorkspaceStore({ reactive: false })
349
+
350
+ // Hydrate from a workspace another store exported. Nothing is re-processed here.
351
+ store.loadWorkspace(exportedWorkspace)
352
+
353
+ // Everything reads exactly as it does by default, `$ref-value` included
354
+ store.workspace.activeDocument?.paths?.['/users']?.get
355
+ ```
356
+
357
+ Documents are still wrapped in the magic proxy, so reference resolution is unchanged, and the whole API — `addDocument`, `loadWorkspace`, `exportWorkspace`, `update`, `updateDocument`, `replaceDocument`, `resolve`, `auth` and the rest — keeps working. Writes take effect and are visible on the next read. They simply notify nobody:
358
+
359
+ - Plugins receive no `onWorkspaceStateChanges` events for the workspace metadata, its documents, `originalDocuments`, `intermediateDocuments` or `overrides`. The auth and history stores keep their own reactivity and still fire their events, and `deleteDocument` still fires its own event.
360
+ - There is no automatic dirty tracking. `x-scalar-is-dirty` changes only where the store writes it directly, in `saveDocument`, `replaceDocument` and `rebaseDocument`.
361
+ - `getDocumentRevision` stays `0` for every document, because it counts the writes the change hooks see.
362
+ - Vue effects and computeds that read the workspace never re-run.
363
+
364
+ A document is also left unwrapped by the overrides proxy unless it actually has overrides, which leaves the magic proxy as the only hop on a read.
365
+
366
+ Use this for a server render, or any other consumer that loads documents and then only reads them. Anything that renders the workspace in Vue, or relies on plugins to persist changes, wants the default.
367
+
270
368
  #### Document Persistence and Export
271
369
 
272
370
  The workspace store keeps two snapshots per document at runtime: the **original** (the last saved baseline that the user committed to with `saveDocument`) and the **active** document (the reactive in-memory state, which may include unsaved edits). Most persistence methods are anchored on those two snapshots.
@@ -486,3 +584,28 @@ await result.applyChanges({ resolvedDocument: newDocument })
486
584
  ```
487
585
 
488
586
  After `applyChanges` returns, the merged document becomes both the new active document and the new saved baseline, so a subsequent `revertDocumentChanges` rolls back to the post-rebase state rather than the pre-rebase original.
587
+
588
+ ## OpenAPI document identity
589
+
590
+ The store honors `$self` when resolving relative references in an OpenAPI 3.2 description. Relative identities resolve against the document source URL. External documents keep their own identities, including across partial bundles.
591
+
592
+ Other OpenAPI bundling callers can opt in with the same plugin:
593
+
594
+ ```ts
595
+ import { bundle } from '@scalar/json-magic/bundle'
596
+ import { fetchUrls } from '@scalar/json-magic/bundle/plugins/browser'
597
+ import { createMagicProxy } from '@scalar/json-magic/magic-proxy'
598
+ import { openApiDocument, resolveOpenApiDocument } from '@scalar/workspace-store/plugins/bundler'
599
+
600
+ const document = await bundle('https://example.com/openapi.json', {
601
+ plugins: [fetchUrls(), openApiDocument()],
602
+ treeShake: false,
603
+ })
604
+ const resolved = createMagicProxy(document, {
605
+ documentUri: resolveOpenApiDocument(document, '/')?.baseUri,
606
+ })
607
+ ```
608
+
609
+ The plugin interprets `$self` only on complete OpenAPI documents. Example payloads and API server URLs are unchanged.
610
+
611
+ Authored reference spellings (including `./` and fragments) are retained across partial bundles and restored by `getEditableDocument`. Loader permissions still apply to the resolved location: `$self` does not enable a loader or widen its file or network access.
package/dist/client.d.ts CHANGED
@@ -3,6 +3,7 @@ import { type Difference, merge } from '@scalar/json-magic/diff';
3
3
  import type { PartialDeep } from 'type-fest';
4
4
  import { type AuthStore } from './entities/auth/index.js';
5
5
  import { type HistoryStore } from './entities/history/index.js';
6
+ import { type ExternalExampleResolver } from './helpers/external-examples.js';
6
7
  import type { NavigationOptions } from './navigation/get-navigation-options.js';
7
8
  import type { InMemoryWorkspace } from './schemas/inmemory-workspace.js';
8
9
  import { type OpenApiDocument } from './schemas/v3.2/strict/openapi-document.js';
@@ -68,6 +69,31 @@ type WorkspaceProps = {
68
69
  plugins?: WorkspacePlugin[];
69
70
  /** A file loader plugin for resolving local file references (for non browser environments) */
70
71
  fileLoader?: LoaderPlugin;
72
+ /**
73
+ * Whether writes to the workspace are observable. Defaults to `true`.
74
+ *
75
+ * When `true`, the workspace is wrapped in Vue's `reactive` and in the change-detection proxy, so a
76
+ * write re-runs Vue effects, fires `onWorkspaceStateChanges` on every registered plugin, flips
77
+ * `x-scalar-is-dirty` and bumps `getDocumentRevision`.
78
+ *
79
+ * When `false`, the workspace and its documents are plain objects and the whole API keeps working
80
+ * unchanged: writes take effect and are visible on the next read, they simply notify nobody. This is
81
+ * for a read-mostly consumer such as a server render, where every property read otherwise pays for
82
+ * Vue reactivity and change detection and nothing observes the result. What does not happen:
83
+ *
84
+ * - no plugin `onWorkspaceStateChanges` events for the workspace meta, its documents,
85
+ * `originalDocuments`, `intermediateDocuments` or `overrides` — the auth and history stores keep
86
+ * their own reactivity and still fire their events, and `deleteDocument` still fires its own
87
+ * - no automatic dirty tracking: `x-scalar-is-dirty` changes only where the store writes it directly
88
+ * (`saveDocument`, `replaceDocument`, `rebaseDocument`)
89
+ * - `getDocumentRevision` stays `0` for every document, since it counts writes seen by the hooks
90
+ * - Vue effects and computeds that read the workspace never re-run
91
+ *
92
+ * A document is also left unwrapped by the overrides proxy unless it actually has overrides, which
93
+ * leaves the magic proxy as the only hop on a read, so `$ref-value` still resolves exactly as it
94
+ * does in the default mode.
95
+ */
96
+ reactive?: boolean;
71
97
  };
72
98
  /**
73
99
  * Type definition for the workspace store return object.
@@ -76,6 +102,8 @@ type WorkspaceProps = {
76
102
  * @see https://github.com/microsoft/TypeScript/issues/43817#issuecomment-827746462
77
103
  */
78
104
  export type WorkspaceStore = {
105
+ /** Resolve external examples without mutating the document or its edit history. */
106
+ externalExamples: (documentName?: string) => ExternalExampleResolver;
79
107
  /**
80
108
  * The history store for the workspace
81
109
  */
@@ -1 +1 @@
1
- {"version":3,"file":"client.d.ts","sourceRoot":"","sources":["../src/client.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,KAAK,YAAY,EAAU,MAAM,2BAA2B,CAAA;AAErE,OAAO,EAAE,KAAK,UAAU,EAAe,KAAK,EAAE,MAAM,yBAAyB,CAAA;AAQ7E,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,WAAW,CAAA;AAI5C,OAAO,EAAE,KAAK,SAAS,EAAmB,MAAM,iBAAiB,CAAA;AACjE,OAAO,EAAE,KAAK,YAAY,EAAsB,MAAM,oBAAoB,CAAA;AAU1E,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,qCAAqC,CAAA;AAY5E,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,8BAA8B,CAAA;AAIrE,OAAO,EAGL,KAAK,eAAe,EACrB,MAAM,wCAAwC,CAAA;AAC/C,OAAO,KAAK,EACV,sBAAsB,EACtB,SAAS,EACT,iBAAiB,EACjB,qBAAqB,EACrB,mBAAmB,EACnB,aAAa,EACd,MAAM,qBAAqB,CAAA;AAC5B,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,mCAAmC,CAAA;AAC/E,OAAO,KAAK,EAAE,eAAe,EAA6B,MAAM,oBAAoB,CAAA;AAgBpF;;;GAGG;AACH,KAAK,0BAA0B,GAAG;IAChC,wEAAwE;IACxE,IAAI,CAAC,EAAE,qBAAqB,CAAA;IAC5B,kDAAkD;IAClD,IAAI,EAAE,MAAM,CAAA;IACZ,iCAAiC;IACjC,SAAS,CAAC,EAAE,WAAW,CAAC,eAAe,CAAC,CAAA;IACxC,wIAAwI;IACxI,KAAK,CAAC,EAAE,CAAC,KAAK,EAAE,MAAM,GAAG,GAAG,GAAG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