Emmet缩写语法乘法将所有元素放在同一行而不是多个行? [英] Emmet abbreviation syntax multiplication puts all elements on same line instead of multiple?

查看:75
本文介绍了Emmet缩写语法乘法将所有元素放在同一行而不是多个行?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在任何地方,我看到人们在VS Code中使用Emmet缩写时,代码编辑器的行为是相同的.如果有人输入以下代码,

Everywhere I see people use Emmet abbreviations in VS Code the behavior of the code editor is the same. If someone puts the following code,

a:link*3

结果如下

<a href="http://"></a>
<a href="http://"></a>
<a href="http://"></a>

但是,当我在自己的VS Code副本中尝试使用它时,似乎分配它们而没有在同一行上返回.

Yet when I try it within my own copy of VS Code it seems to distribute them without a return on the same line.

<a href="http://"></a><a href="http://"></a><a href="http://"></a>

是否可以在设置中修改此行为?我不确定这是否重要,但是我正在使用Apple M1 MBA的1.53.0版.

Is there any way to modify this behavior within the setting? I'm not sure if it matters but I'm on version 1.53.0-exploration on an Apple M1 MBA.

推荐答案

"emmet.preferences": {
  "output.inlineBreak": 1
}

这似乎是更好的技术,请参见 https://github.com/microsoft/vscode/issues/119088#issuecomment-811297787 作为 emmet.syntaxProfiles inline_break 本身不受emmet本身的支持,但在vscode.因此,可能会在某些时候弃用它,而推荐使用 emmet.preferences 方法.

This appears to be the better technique, see https://github.com/microsoft/vscode/issues/119088#issuecomment-811297787 as the emmet.syntaxProfiles and inline_break isn't actually supported by emmet itself but an addition in vscode. So it may be deprecated at some point in favor of emmet.preferences approach.

这篇关于Emmet缩写语法乘法将所有元素放在同一行而不是多个行?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆