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

Enhance API documentation with Swagger #34

Open
wants to merge 1 commit into
base: dev/second-branch
Choose a base branch
from

Conversation

yashksaini-coder
Copy link
Member

@yashksaini-coder yashksaini-coder commented Feb 16, 2025

Fixes #5

Add Swagger API documentation to the project.

  • internal/structure/structure.go

    • Add a new function AddSwaggerDocs to set up Swagger documentation.
    • Call AddSwaggerDocs in CreateBaseFileStructure after copying the directory.
  • .templates/jsbase/src/app.js

    • Import swagger-ui-express and swagger-jsdoc.
    • Define Swagger documentation in JSDoc format.
    • Set up Swagger UI to serve at /api-docs.
  • .templates/tsbase/src/app.ts

    • Import swagger-ui-express and swagger-jsdoc.
    • Define Swagger documentation in JSDoc format.
    • Set up Swagger UI to serve at /api-docs.

Fixes DEVRhylme-Foundation#5

Add Swagger API documentation to the project.

* **internal/structure/structure.go**
  - Add a new function `AddSwaggerDocs` to set up Swagger documentation.
  - Call `AddSwaggerDocs` in `CreateBaseFileStructure` after copying the directory.

* **.templates/jsbase/src/app.js**
  - Import `swagger-ui-express` and `swagger-jsdoc`.
  - Define Swagger documentation in JSDoc format.
  - Set up Swagger UI to serve at `/api-docs`.

* **.templates/tsbase/src/app.ts**
  - Import `swagger-ui-express` and `swagger-jsdoc`.
  - Define Swagger documentation in JSDoc format.
  - Set up Swagger UI to serve at `/api-docs`.

---

For more details, open the [Copilot Workspace session](https://copilot-workspace.githubnext.com/DEVRhylme-Foundation/expressify/issues/5?shareId=XXXX-XXXX-XXXX-XXXX).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Enhance API Documentation with Swagger
1 participant