簡體   English   中英

Emmet-我可以寫HTML以便CSS結構自動生成嗎?

[英]Emmet - Can I write html so that the css structure will generate automatically?

我有一個問題。 我使用Emmet編寫html。 我可以編寫html以便CSS結構自動生成嗎? 例如...我寫這段​​代碼:

div.wrapper>div.head>a.logo+h1{Some text}

我會得到這個:

<div class="wrapper">
 <div class="head">
  <a href="" class="logo"></a>
  <h1>Some text</h1>
 </div>
</div>

我想要這個結果:

<div class="wrapper">
 <div class="head">
  <a href="" class="logo"></a>
  <h1>Some text</h1>
 </div>
</div>
<style>
   .wrapper {}
   .wrapper .head {}
   .wrapper .head a.logo {}
   .wrapper .head a:hover.logo {}
   .wrapper .head h1 {}
</style>

可能嗎?

你檢查底漆嗎? 我想這就是您要的。

暫無
暫無

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

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