簡體   English   中英

Html 在 vs 代碼中格式化

[英]Html formatting in vs code

我正在尋找一個格式化程序,在 vscode 或在線,將采用這些代碼行:

<button class="button button1" type="button">Green</button>
<button type="button" class="button button1">Blue</button>

並將格式化標簽以按順序排列道具:

<button class="button button1" type="button">Green</button>
<button class="button button1" type="button">Blue</button>

我找到了這個擴展: Sorting HTML and Jade attributes

打開 html 文件。

按 F1 並運行名為 Sorting of the tag attributes (attrs-sorter) 的命令

安裝鏈接

使用來自 vscode 市場的美化,調整格式化快捷方式的設置默認快捷方式: Windows Shift + Alt + F

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM