-
-
Notifications
You must be signed in to change notification settings - Fork 216
Open
Description
Prerequisites
- I have written a descriptive issue title
- I have searched existing issues to ensure the issue has not already been raised
Issue
I spent hours trying to figure out myself, but I cannot seem to manage to generate multiple documents.
With this:
const generateOpenApiDocumentation =
(server: Server) => async (version: string) => {
const { name, baseUrl } = AppConfig;
await server.register(FastifySwagger.fastifySwagger, {
openapi: {
info: {
title: `${name} API`,
version,
},
servers: [/* ... */],
},
prefix: `/api/${version}`,
});
};
// ...
for (const version of PUBLISHED_VERSIONS) {
await generateOpenApiDocumentation(server)(version);
}I get : FST_ERR_DEC_ALREADY_PRESENT: The decorator "swagger" has already been added.
If I use encapsulation as described here:
#213
Then both of my generated documents have no routes...
Isn't it possible to have the auto mode with encapsulation ?
Metadata
Metadata
Assignees
Labels
No labels