保存时:
<template>
<div> <div></div> </div>
</template>
VSCode会自动将代码格式化为:
<template>
<div>
<div></div>
</div>
</template>
ESLint只允许在同一行上具有单个子元素的元素,所以我总是会遇到这种错误:
https://google.com/#q=prettier%2Fprettier Replace `⏎················<router-view></router-view>⏎···········` with `·<router-view></router-view>`
如何解决此问题,以便在保存文件时vscode不会添加新的换行符?