typelab / assertions / IsNewableFunction
type IsNewableFunction<T> = _IsTrue<IfNewableFunction<T, true, false>>;Checks if a given type T is a newable function type.
| Type Parameter | Description |
|---|---|
|
|
The type to be checked. |
true if T is a newable function type, false otherwise.
type Valid = IsNewableFunction<new () => string>; // true
type Invalid = IsNewableFunction<() => string>; // false