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

feat: generate GraphQL descriptions from CDS doc comments #30

Merged
merged 25 commits into from
Nov 23, 2023
Merged

Conversation

schwma
Copy link
Member

@schwma schwma commented Jan 5, 2023

Turns CDS doc comments of services, entities, and elements:

/** A Chapter of a Book */
entity Chapters : managed {
  key book   : Association to bookshop.Books;
  key number : Integer;
      title  : String;
}

into GraphQL descriptions:

"""A Chapter of a Book"""
type AdminService_Chapters {
  book: AdminService_Books
  book_ID: Int
  createdAt: Timestamp

  """Canonical user ID"""
  createdBy: String
  modifiedAt: Timestamp

  """Canonical user ID"""
  modifiedBy: String
  number: Int
  title: String
}

when compilation of doc comments in enabled in the CDS compiler options.

@schwma schwma marked this pull request as ready for review November 21, 2023 13:53
@schwma schwma requested a review from a team as a code owner November 21, 2023 13:53
@schwma schwma changed the title feat: support for generating GraphQL descriptions from CDS doc comments feat: generate GraphQL descriptions from CDS doc comments Nov 21, 2023
@schwma schwma merged commit d792ed1 into main Nov 23, 2023
3 checks passed
@schwma schwma deleted the doc-comments branch November 23, 2023 10:36
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.

2 participants