eslint-config
eslint-config copied to clipboard
How to enable formatting for class names in html?
I almost completely covered all my formatting and linting needs but there is still 1 thing which is that classes are just not getting formatted.
class="test-sm
ml-2
overflow-hidden
white-space-nowrap text-overflow-ellipsis"
If I leave this in one line then max length complains. Essentially nothing is fixed that is inside the class, I can leave empty spaces, bad tabbing or anything there.
In my eslint config I currently have:
export default withNuxt(
antfu(
{
formatters: {
css: true,
html: true,
},
lessOpinionated: true,
},
{
rules: {
'style/max-len': ['error', 80, { ignoreComments: true }],
'vue/max-attributes-per-line': ['error', {
singleline: {
max: 1,
},
multiline: {
max: 1,
},
}],
},
},
),
)
Any help would be greatly appreciated! Thank you!