Skip to content

Extending @typedefs by adding additional properties doesn't seem to work? #42877

Open
@sami616

Description

@sami616

I know this can be done with an intersection type, but that can often get quite verbose as it often requires an additional typedef to be defined.

As you can see in the below screenshot, i would expect propThree to be present in the extended const.

Is this syntax supported by vscode, looking around it seems to be in webstorm?

Screenshot 2021-02-19 at 10 20 36

Sandbox example: https://codesandbox.io/s/vigilant-https-7h845?file=/src/Animal.js

Metadata

Metadata

Assignees

Labels

Needs ProposalThis issue needs a plan that clarifies the finer details of how it could be implemented.SuggestionAn idea for TypeScript

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions