In order to streamline code sharing between two classes that overlap, I decided to create a new class called Common
.
For one of the subclasses, I needed all the properties from the Common
class to be required. My initial thought was to utilize the Required utility type in the following manner:
class A extends Common {
//...
}
class B extends Required<Common> {
//...
}
Unfortunately, I encountered an error stating that Required
is not defined. Is there a straightforward solution to achieve my desired outcome, or should I consider revising the code entirely?