I have the following situation:
type WithSymbols<T extends Record<string, unknown>> = T & {
readonly [K in keyof (LogicSymbols | T) as LogicSymbols[K]]: T[K];
};
interface WithAAndB
extends WithSymbols<{ propA: boolean; }>,
WithSymbols<{ propB: boolean; }> {
}
let variable: WithAAndB;
let a = variable.propA; // rendered just fine
let b = variable.propB; // unresolved variable propB
IntelliJ tells me this cannot happen as it won’t read the second extension propB
. Strangely this is fine within VScode (it will read propB just fine) and both use typescript 5.5.2.
My question: is this valid typescript? And if so, how do I get IntelliJ to read it properly? If not, how would I fix it?