Replies: 3 comments 4 replies
-
Can you give me an example config, example file, and tell me what it should format and what it shouldn't format? |
Beta Was this translation helpful? Give feedback.
0 replies
-
// eslint.config.js
import antfu from '@antfu/eslint-config'
export default antfu(
{
// unocss: true,
formatters: {
css: false,
},
},
{
rules: {
'vue/multi-word-component-names': 'off',
'no-console': ['error', { allow: ['debug', 'error', 'timeEnd', 'time'] }],
'node/prefer-global/process': 'off',
},
},
) Formatted by Zed <script setup lang="ts">
// the formatting zed does
</script>
<template>
<div class="w-full flex items-center">
<div class="layout" :class="{
'blocks': preferences.ui.style === 0,
'no-blocks': preferences.ui.style === 1,
'layout-default': preferences.ui.layout === 1,
}">
<!-- -->
</div>
</div>
</template> Formatted by running manual command eslint [file.vue] --fix <script setup lang="ts">
// ...
</script>
<template>
<div class="w-full flex items-center">
<div
class="layout" :class="{
'blocks': preferences.ui.style === 0,
'no-blocks': preferences.ui.style === 1,
'layout-default': preferences.ui.layout === 1,
}"
>
<!-- -->
</div>
</div>
</template> A specific rule that is not being applied is this vue/first-attribute-linebreak |
Beta Was this translation helpful? Give feedback.
0 replies
-
#9213 does this fix this problem? or it's nothing to do with this? |
Beta Was this translation helpful? Give feedback.
4 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I see there is support for ESLint and Flat config. I'm using
@antfu/eslint-config
to generate flat config for my Vue project. and have this zed settings but formatting / fixing is not respectingeslint-plugin-vue
's rules. Is this supported or still in wip?Beta Was this translation helpful? Give feedback.
All reactions