-
Notifications
You must be signed in to change notification settings - Fork 63
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support for feathers v5 (Dove) #240
Comments
Hi, the branch should work with express and koa. But the schemas are not automatically consumed, and this will never be possible. I have working examples (with
But be aware that I plan to add breaking changes, to support the Typebox schemas in a more convenient way. import { ServiceSwaggerOptions, createSwaggerServiceOptions } from 'feathers-swagger';
import { userSchema, userDataSchema, userQuerySchema } from './users.schema';
export class UserService extends KnexService<User, UserData, UserParams> {
docs: ServiceSwaggerOptions = createSwaggerServiceOptions({
schemas: { userDataSchema, userQuerySchema, userSchema },
docs: {
securities: ['find', 'get', 'update', 'patch', 'remove'],
}
});
} |
I can confirm the branch works as you said. 👍 But i then stumbled upon the typebox schema issue. Would be great to be able to configure this in a more convenient way. |
Could we add schema (and other OpenApi) information with the new service options and auto generate things from that? |
Sounds like a logical place to put it to me, but then i don't know the inner working of feathersjs at all. 🤷♂️ |
Sure the swagger service options could also be loaded from the service options, but it would not change the general approach. It would be possible to set them from both, the service object property and the service options. Or would you prefer to not have to call that function for the service options? (I think that would make typing more difficult) |
Pre release has been published as 3.0.0-pre.0 |
@Mairu Hi, I just created a new app followed the steps defined here. I need Swagger UI so added docsPath: "/docs" but I see |
@nickdex There is a pre-release for feathers 5, so if you install |
Version 3.0.0 with dove support was released. |
I might be building a new feathers app soon and since dove (v5) is around the corner, i've tried using the current pre-31 version of it. So far all almost all our requirements are fulfilled, except for swagger/openapi integration which is not yet v5 compatible.
Is there a timeline for supporting it?
I have tried the
custom-methods-v5
branch and could get it to work by installing thekoa-mount
dependency. But it does not automatically generate the exposed services in the swagger.json. Manually settingsdocs
on properties also fails.Do you know how to get it working or is this something you have not looked into yet? If there is a (manual) way, i would be interested. Thanks.
The text was updated successfully, but these errors were encountered: