Skip to content
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 auto-generating models based on Swagger / OpenAPI Specifications #1780

Open
2 tasks done
JeffJassky opened this issue Feb 18, 2024 · 1 comment
Open
2 tasks done
Labels
enhancement New feature or request help wanted Extra attention is needed

Comments

@JeffJassky
Copy link

JeffJassky commented Feb 18, 2024

Describe the feature

pinia-orm is a perfect candidate for supporting Swagger / OpenAPI spec for schemas.

Considering that schemas and API paths are well-defined in an OpenAPI spec file (yml, or json), it wouldn't be too difficult have a builder that would auto-generate ORM models, and even axios requests, along with validation of the request bodies and response bodies, based on the OpenAPI/Swagger spec - all with full typescript support.

I wrote a Vite plugin for my monorepo builds all of the above based on my apo spec file, plus it builds the express routes, zod/yup schemas, mongoose schemas. However, my system currently lacks support for client-side ORM.

I am considering wrting an additional builder for pinia-orm models - however, i'll have to do some testing with it to ensure pinia-orm is a good solution for my app before i commit to building a code generator, and wanted to drop the idea in here in the meantime.

Additional information

  • Would you be willing to help implement this feature?

Final checks

@CodeDredd
Copy link
Owner

That sounds nice. It's always nice to have some tool more in the ecosystem.

@CodeDredd CodeDredd added enhancement New feature or request help wanted Extra attention is needed and removed pending triage labels May 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

2 participants