You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The v0.3.0 migration accidentally made full and compact files identical
by applying withCompactUris() to both. This fix restores the semantic
difference from v0.2.x:
- <name>.json (full): expanded URIs, source maps on by default.
Intended for editing tools and validators. Source maps can be
disabled via sourceMaps: false in ApiConfiguration.
- <name>-compact.json: compact URIs (apiContract:WebAPI prefixes),
never includes source maps. Optimized for display/browsing (e.g.
API Console). Can reduce model size by up to 80% for large APIs.
Both files share the same parse and transform step; only the render
options differ, so there is no performance regression.
Made-with: Cursor
Copy file name to clipboardExpand all lines: README.md
+10-1Lines changed: 10 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -30,7 +30,16 @@ If the value is an array then first element must be API format and second is API
30
30
`ApiDefinition.mime` ⇒ `String`. API media type. Default to `application/yaml`. For GRPC use `application/x-protobuf`.
31
31
`ApiDefinition.resolution` ⇒ `String`. AMF resolution pipeline. Default to `editing` which is the original resolution pipeline for API Console. Future releases of AMF can support different options.
32
32
`ApiDefinition.flattened` ⇒ `Boolean`. When `true`, generates a compact JSON-LD model using `@graph` instead of an expanded array. Recommended for large APIs. Default to `false`.
33
-
`ApiDefinition.sourceMaps` ⇒ `Boolean`. When `false`, omits AMF source map nodes from the generated model. Source maps are only needed for editing tooling (e.g. API designers). Disabling them can reduce model size by up to 80% for large APIs like gRPC. Default to `true`.
33
+
`ApiDefinition.sourceMaps` ⇒ `Boolean`. Controls source maps in the **full** model (`<name>.json`) only. When `false`, source map nodes are omitted — useful when no editing tooling will consume this API. The compact model (`<name>-compact.json`) never includes source maps. Default to `true`.
0 commit comments