molindo / eslint-config-molindo

ESLint config that implements the Molindo styleguide and helps to catch errors.
MIT License
1 stars 2 forks source link

Sort React prop types #4

Closed amannn closed 4 years ago

amannn commented 6 years ago

Could be interesting to mirror the setting from react/jsx-sort-props. However this isn't helpful as long as issues reported by the rule can't be fixed automatically.

amannn commented 5 years ago

Update: react/sort-prop-types can now be fixed automatically 🎉. What's missing though, is moving leading comments together with the prop type. There's an open PR for this though which looks like it might make it to the codebase.

Enabling react/jsx-sort-default-props might be a good idea as well, however this rule is currently not auto-fixable. Also note that the rule might get renamed to react/sort-default-props.