I’m looking for an ESLint rule with similar capabilities to react/jsx-sort-props
but for interfaces and types, where I can require to sort interface members alphabetically, with members of type function
going last.
Wrong example:
interface I {
b: string;
ab: () => void;
a: string;
}
Correct example:
interface I {
a: string;
b: string;
ab: () => void;
}
Does a rule for this exist? So far, I’ve only found rules that sort members alphabetically, but they don’t have a setting to require functions to go last.