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

Generate Comments for Typescript Model Properties #3

Closed
texttechne opened this issue Jul 2, 2021 · 1 comment · Fixed by #173
Closed

Generate Comments for Typescript Model Properties #3

texttechne opened this issue Jul 2, 2021 · 1 comment · Fixed by #173

Comments

@texttechne
Copy link
Contributor

Add additional information from odata metadata to generated typescript interfaces:

  • string: MaxLength
  • decimal: precision & scale
@texttechne
Copy link
Contributor Author

Keept it more general and also explain special data types.
Something along these lines:

export interface BookEntity {
  /**
   * Key Property: This is a key property used to identify objects.
   * Managed: This property is managed on the server side and cannot be edited.
   *
   * Data Type: GUID string - plain string which should match GUID pattern
   *
   * OData attributes:
   * - Name="ID"
   * - Type="Edm.Guid"
   * - Nullable="false"
   * - MaxLength="15"
   * @example
   * "12345678-BBBb-cCCCC-0000-123456789012"
   */
  id: GuidString;

@texttechne texttechne changed the title odata2model: generate comments for typescript interface attributes Generate Comments for Tpescript Interface Attributes Jan 7, 2023
@texttechne texttechne changed the title Generate Comments for Tpescript Interface Attributes Generate Comments for Typescript Model Properties Jun 11, 2023
@texttechne texttechne linked a pull request Jun 11, 2023 that will close this issue
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 a pull request may close this issue.

1 participant