2 Matching Annotations
- Nov 2021
-
-
Error: Index signature for type 'string' is missing in type 'someInterface'. Because `interface` can be re-opened
Didn't understand at first: How is it because
interface
can be re-opened?Found the answer here: https://hyp.is/Nyiq5js7Eey8Gpe0OK6smQ/stackoverflow.com/questions/67184371/type-session-is-not-assignable-to-type-recordstring-unknown
-
-
-
An interface can be re-opened. Whereas a type is sealed. So a solution for microsoft/TypeScript#15300 is to map the interface (which can be defined in many places) to a type.
-