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

Provide a generic dictionary of decorators in TCGC for better extensibility #829

Open
4 tasks done
live1206 opened this issue May 14, 2024 · 0 comments · May be fixed by #966
Open
4 tasks done

Provide a generic dictionary of decorators in TCGC for better extensibility #829

live1206 opened this issue May 14, 2024 · 0 comments · May be fixed by #966
Assignees
Labels
lib:tcgc Issues for @azure-tools/typespec-client-generator-core library

Comments

@live1206
Copy link
Member

live1206 commented May 14, 2024

Clear and concise description of the problem

Nowadays when we add a new decorator, TCGC needs to process it and add a new property to SDK model.

We would like to have a generic dictionary to store decorators for emitter to consume, so that we don't need to add a new property to SDK model for better extensibility.

decorators
{
  "decoratorName":  string,   // The name should include namespace
  "decoratorArguments": string[]
}

Issues to address:

  • how to filter which decorators to include in the generic dictionary
  • how to present the decorator arguments/values in the dictionary, such as JSON serialization, need to analyze the existing decorators

Checklist

  • Follow our Code of Conduct
  • Check that this issue is about the Azure libraries for typespec. For feature request in the typespec language or core libraries file it in the TypeSpec repo
  • Read the docs.
  • Check that there isn't already an issue that request the same feature to avoid creating a duplicate.
@live1206 live1206 added the lib:tcgc Issues for @azure-tools/typespec-client-generator-core library label May 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
lib:tcgc Issues for @azure-tools/typespec-client-generator-core library
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants