Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR HTML

how to format vue html with prettier

//unexpected Format
<span class="dolorum atque aspernatur"
  >Est molestiae sunt facilis qui rem.</span
>
//Expected Format
<span class="dolorum atque aspernatur">
  Est molestiae sunt facilis qui rem.
</span>

//Adding this to the .prettierrc or .prettierrc.json file seems to fix this kind of issue:

"htmlWhitespaceSensitivity": "ignore"



Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #format #vue #html #prettier
ADD COMMENT
Topic
Name
7+5 =