react-native-macos/packages
Tom Spencer 722a0ff6f8 Fix eslint no-shadow issue with TypeScript enums (#32644)
Summary:
The current ESLint config includes a rule for `no-shadow`. When authoring using TypeScript, the [typescript-eslint docs](https://github.com/typescript-eslint/typescript-eslint/blob/main/packages/eslint-plugin/docs/rules/no-shadow.md) mention that the base `no-shadow` rule should be disabled in favour of `typescript-eslint/no-shadow`, otherwise false positives can be reported. In my case, I was experiencing the same symptoms as described in [this issue](https://github.com/typescript-eslint/typescript-eslint/issues/2552).

## Changelog

<!-- Help reviewers and the release process by writing your own changelog entry. For an example, see:
https://github.com/facebook/react-native/wiki/Changelog
-->

[General] [Fixed] - ESLint `no-shadow` rule returning false positive for TypeScript enums

Pull Request resolved: https://github.com/facebook/react-native/pull/32644

Test Plan:
Before config changes:

<img width="631" alt="Screenshot 2021-11-22 at 21 02 31" src="https://user-images.githubusercontent.com/820863/142934803-ef1343d6-46ab-4495-9ea5-957f7ec404fc.png">

After changes:

<img width="486" alt="Screenshot 2021-11-22 at 21 03 28" src="https://user-images.githubusercontent.com/820863/142934914-a151656a-a37e-4ffb-9db5-ed9fb93543c7.png">

Reviewed By: GijsWeterings

Differential Revision: D32618393

Pulled By: yungsters

fbshipit-source-id: c69d5cff7210c22c84a0791bde62674efc6aa027
2021-12-01 14:09:34 -08:00
..
assets Assume *.ktx assets are packaged as Android drawables 2021-11-22 13:56:53 -08:00
babel-plugin-codegen JS: Format with Prettier v2.4.1 [3/n] 2021-11-02 22:14:16 -07:00
eslint-config-react-native-community Fix eslint no-shadow issue with TypeScript enums (#32644) 2021-12-01 14:09:34 -08:00
eslint-plugin-codegen JS: Format with Prettier v2.4.1 [3/n] 2021-11-02 22:14:16 -07:00
eslint-plugin-react-native-community JS: Format with Prettier v2.4.1 [3/n] 2021-11-02 22:14:16 -07:00
normalize-color Fix invalid @flow modes in xplat 2021-11-17 20:47:42 -08:00
polyfills RN: Follow-up Format w/ Prettier v2.x 2021-11-09 13:16:43 -08:00
react-native-codegen Do not .lowerCase the library name when codegenerating TurboModule Specs 2021-11-24 11:57:52 -08:00
react-native-gradle-plugin Make hermes-executor-common a static lib (#32683) 2021-12-01 11:19:23 -08:00
rn-tester Build codegen package in pod install (#32678) 2021-11-30 17:11:17 -08:00