vue/static-class-names-order
eslint-plugin-vue
Safe autofix
eslint.config.js
import vue from "eslint-plugin-vue";
export default [
{
plugins: { vue },
rules: {
"vue/static-class-names-order": "error",
},
},
]; <div class="b a"></div>
</template><div class="a b"></div>Examples from the ESLint documentation.
No tracked preset enables this rule, so it has no reach yet.
None of the tracked presets enable this rule. Turn it on with the config below.
vue/static-class-names-order
eslint-plugin-vue
import vue from "eslint-plugin-vue";
export default [
{
plugins: { vue },
rules: {
"vue/static-class-names-order": "error",
},
},
];Oxlint does not have this rule.
Biome does not have this rule.
Enforce sort-keys in a manner that is compatible with order-in-components
Require key attribute for conditionally rendered repeated components