Microsoft/TypeScript
GitHub ã§èŠãIntellisense stops working inside nested `Array.map`
Open
#51,823 opened on 2022幎12æ8æ¥
Domain: LS: Completion ListsExperience EnhancementHelp WantedSuggestion
Repository metrics
- Stars
- Â (48,455 stars)
- PR merge metrics
-  (å¹³åããŒãž 6d 17h) (30d ã§ 9 merged PRs)
説æ
Bug Report
ð Search Terms
Intellisense stops working inside Array.map
ð Version & Regression Information
- Version 4.9.3
⯠Playground Link
Playground link with relevant code
ð» Code
type Children = {
name: string;
};
type Parent = {
children: Children[];
};
let parents: Parent[] = [].map(() => ({ children: [].map(() => ({ /* Missing `name` property in intellisense */ })) }))
ð Actual behavior
Missing name property in intellisense

ð Expected behavior
Have name property in intellisense
Note
I know I can put map<Children> to show intellisense, but using complex types like prisma, and with a lot of nested array, it wouldn't be very convenient to keep putting map<Type> (even worse if the type is in another file needs to be imported)