79098905

Date: 2024-10-17 15:52:58
Score: 1
Natty:
Report link

What you need is Record<..., ...> I believe.

So, in this case it could be rewritten as:

export interface QualitiesInterface extends Record<QualityStrings, number> {}

Basically we're 'converting' type to interface above with the use of extension semantics:

interface SomeThing extends MyType {
   // normal iface stuff can be added here if needed
}
Reasons:
  • Has code block (-0.5):
  • Starts with a question (0.5): What you
  • Low reputation (1):
Posted by: thodnev