We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
assign
my constructors usually follow the pattern:
class It { prop1: string prop2: string constructor(props: It) { (_ || Object).assign(this, props); } }
With this though, I get the error
property 'prop1' has no initializer and is definitely not assign in the constructor
Though it is.
Typing out all properties in constructor, constructor params and class vars is sadly redundant.
Typescript apparently has the inner workings for assignment awareness, can this be extended to assigning functions?
Above I'm sure other people can find some dope use cases for an assign type descriptor.
My suggestion meets these guidelines:
The text was updated successfully, but these errors were encountered:
Duplicate of #26792
Sorry, something went wrong.
This issue has been marked as a duplicate and has seen no activity in the last day. It has been closed automatic house-keeping purposes.
No branches or pull requests
Search Terms
assign
Suggestion
my constructors usually follow the pattern:
With this though, I get the error
Though it is.
Typing out all properties in constructor, constructor params and class vars is sadly redundant.
Typescript apparently has the inner workings for assignment awareness, can this be extended to assigning functions?
Use Cases
Above
I'm sure other people can find some dope use cases for an assign type descriptor.
Checklist
My suggestion meets these guidelines:
The text was updated successfully, but these errors were encountered: