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

Get type of generic type. #10576

Closed
joesonw opened this issue Aug 27, 2016 · 1 comment
Closed

Get type of generic type. #10576

joesonw opened this issue Aug 27, 2016 · 1 comment
Labels
Design Limitation Constraints of the existing architecture prevent this from being fixed

Comments

@joesonw
Copy link

joesonw commented Aug 27, 2016

TypeScript Version: : 2.1.0-dev.20160721

I understand that reflect-metadata retrieves the metadata information for me. However, It can only get the outmost type.

Say, I wanted to get the return type of async function():Promise<string>, it can tells me its a promise. Same goes for Array<T>.

Is there a plan for providing nested types? Or there is already a way?

@mhegazy mhegazy added the Design Limitation Constraints of the existing architecture prevent this from being fixed label Aug 29, 2016
@mhegazy
Copy link
Contributor

mhegazy commented Aug 29, 2016

This is not possible without a full type serialization scheme. you can find a long discussion about this in #3628

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Design Limitation Constraints of the existing architecture prevent this from being fixed
Projects
None yet
Development

No branches or pull requests

2 participants