A
A
antpv2019-04-29 19:33:58
Vue.js
antpv, 2019-04-29 19:33:58

Why doesn't vue template html formatting through prettier work?

.prettierrc

trailingComma: "none"
bracketSpacing: true
tabWidth: 2
semi: false
singleQuote: true
jsxBracketSameLine: false

I want to get the end result:
<div
  class="text"
  :class="textClass"
  v-if="!searchText.length"
>
    {{ inputText }}
</div>

Current result:
<div class="text" :class="textClass" v-if="!searchText.length">{{ inputText }}</div>

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question