TypeScript type definitions for eslint-plugin-react-hooks are incorrect.
The issue reports incorrect TypeScript type definitions in eslint-plugin-react-hooks, specifically around the flat config's recommended property. The types need to be updated to properly reflect the possible return values. The problem is reproducible but requires TypeScript and eslint configuration knowledge.
React version:
eslint.config.ts like pluginReact.configs.flat.recommendedType 'ReactFlatConfig | undefined' is not assignable to type 'InfiniteArray<ConfigWithExtends>'.
Type 'undefined' is not assignable to type 'InfiniteArray<ConfigWithExtends>'.
Link to code example:
Forced to use non-null assertion but it is banned in my eslint config =)
Types can declare each existing property of flat object
Claim this issue to let others know you're working on it. You'll earn 10 points when you complete it!