React version:
Steps To Reproduce
- npm i eslint-plugin-react-hooks
- configure TypeScript to strict mode,
- use plugin in
eslint.config.ts like pluginReact.configs.flat.recommended
- See error:
Type 'ReactFlatConfig | undefined' is not assignable to type 'InfiniteArray<ConfigWithExtends>'.
Type 'undefined' is not assignable to type 'InfiniteArray<ConfigWithExtends>'.
Link to code example:
The current behavior
Forced to use non-null assertion but it is banned in my eslint config =)
The expected behavior
Types can declare each existing property of flat object