Utility type for writing types for classes more concisely.
function createInstance<T>(aClass: InstantiableClass<T>): T { return new aClass();}const instance: RegExp = createInstance(RegExp); Copy
function createInstance<T>(aClass: InstantiableClass<T>): T { return new aClass();}const instance: RegExp = createInstance(RegExp);
If the class may be abstract, you must use Class.
Utility type for writing types for classes more concisely.
If the class may be abstract, you must use Class.