-
Notifications
You must be signed in to change notification settings - Fork 174
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
Offer completions for model properties when model extends another model #3130
Comments
it's also better to clarify these completions are for override scenario somehow so that they won't confuse people we are not using overrides. |
You can override, but the type you override with has to be a subtype of the base. So in your example, if you set
Can you say more about what the potential confusion is? |
I think it would be confusing for user who is new to typespec and not familiar with the property override feature. Like when I first look at the issue, I just wondered why the intellisense needs to suggest me with the properties of parent type? do i need to define them again in the subtype for things to work (like implement interface in ts)? i just didn't realize it's for override... (i guess it may also because i am used to c# and would think about override scenario only when I type override/new keyword...) thx |
…odel (#3280) add following feature 1. support completion when user typing model expression as decorator argument value 2. support completion for extended model 3. support showing decorator model argument prop information when hovering on model expression as decorator argument value closes #3130, closes #2228, closes #1956 --------- Co-authored-by: Timothee Guerin <timothee.guerin@outlook.com>
Clear and concise description of the problem
This would be very handy, especially when you are modelling complex data shapes with inheritance rather than templates.
Checklist
The text was updated successfully, but these errors were encountered: