Intellicode / eslint-plugin-react-native

React Native plugin for ESLint
MIT License
722 stars 130 forks source link

Unhandled case no-inline-styles + typescript when add type casting `as T` #295

Closed retyui closed 3 years ago

retyui commented 3 years ago

Our tricky developers found a way to ignore eslint rule:

// 1) Work as expected (eslint error : no-inline-styles )
<View style={{width: 1}} /> 

// 2) No error
<View style={{width: 1} as ViewStyle} /> 

Can you fix it?