Function isClass

Check if a value is a class (instead of a "normal" function), with a type guard, so you can new value() without TS errors.