fumadocs-openapi 9.0.0
Major Changes
-
bdef238: Redesign
generateFilesThis redesign will finalize the behaviour of
generateFilesto make it simpler, consistent across different versions of Fumadocs OpenAPI.- Abandoned
groupByFolder, it's deprecated long time ago and can be replaced withgroupBy. - Improved type safety,
groupByis now only available withperset tooperation. nameusage changed (see below).
The
nameoption was supposed to designate a output path for generated page. SincegroupBywas introduced,namebecame somehow useless because its design doesn't work well withgroupBy.New
nameDesign:It now accepts a function:
generateFiles({ input: ['./content/docs/openapi/museum.yaml'], output: './content/docs/openapi/(generated)', per: 'operation', name: (output, document) => { // page info output.item; // parsed OpenAPI schema document; return 'dir/my-file'; }, });You can set
algorithmtov1to keep the behaviour of Fumadocs OpenAPI v8:generateFiles({ input: ['./content/docs/openapi/museum.yaml'], output: './content/docs/openapi/(generated)', per: 'operation', name: { algorithm: 'v1', }, });per: operation:File name will be identical with your
operationIdif defined, otherwise fallback to endpoint path or webhook name.generateFiles({ input: ['./content/docs/openapi/museum.yaml'], output: './content/docs/openapi/(generated)', per: 'operation', });With
per: operation, you can usegroupByto group pages:- tag:
{tag}/{file} - route:
{endpoint}/{method}(it will ignore thenameoption) - none:
{file}(default)
per: tag | file:They are unchanged.
- Abandoned
Minor Changes
- c945b5f: Mark
mediaAdaptersAPI stable - b0c02a0: Redesign schema display UI
Patch Changes
- 00a81e1: Improve playground body input
- 1bcdc84: Fix recursive reference in
anyOf/allOf/oneOf - Updated dependencies [092fd04]
- Updated dependencies [1b999eb]
- Updated dependencies [961b67e]
- Updated dependencies [7d78bc5]
- fumadocs-ui@15.4.0
- fumadocs-core@15.4.0