dsherret / dsherret/ts-morph

How do I get base type of a generic class

Open
#1,295 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
TypeScript
Stars
6.2k
Forks
238
Avg merge
2m
Merged PRs (30d)
1

Description

let say I have generic class

class Request {
field1: T
field2: K
obj: L
}

I know I can get by calling getTypeArguments()

Is there a method to get the class **Request** without generic args?

For this type I call .isClass() and it returns false. Is there another method to check it's a class?

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.