Emmet 介紹 – 縮寫篇
縮寫這樣的編輯方式是Emmet的核心功能,可以在輸入簡短的代碼後轉換成結構複雜的HTML,而且使用方式跟使用CSS的選取器雷同,所以非常易於使用。例如:
page>div.logo+ul#navigation>li*5>a{Item $} ------ <div id="page"> <div class="logo"></div> <ul id="navigation"> <li><a href="">Item 1</a></li> <li><a href="">Item 2</a></li> <li><a href="">Item 3</a></li> <li><a href="">Item 4</a></li> <li><a href="">Item 5</a></li> </ul> </div>
以下分別介紹各種不同的縮寫撰寫模式
子結構:>
div>ul>li ------ <div> <ul> <li></li> </ul> </div>
同層結構:+
div+p+bq ------ <div></div> <p></p> <blockquote></blockquote>
上一層:^
div+div>p>span+em^bq ------ <div></div> <div> <p><span></span><em></em></p> <blockquote></blockquote> </div>
div+div>p>span+em^^^bq ------ <div></div> <div> <p><span></span><em></em></p> </div> <blockquote></blockquote>
乘法:*
ul>li*5 ------ <ul> <li></li> <li></li> <li></li> <li></li> <li></li> </ul>
分組:( )
div>(header>ul>li*2>a)+footer>p ------ <div> <header> <ul> <li><a href=""></a></li> <li><a href=""></a></li> </ul> </header> <footer> <p></p> </footer> </div>
(div>dl>(dt+dd)*3)+footer>p ------ <div> <dl> <dt></dt> <dd></dd> <dt></dt> <dd></dd> <dt></dt> <dd></dd> </dl> </div> <footer> <p></p> </footer>
項目編號:$
ul>li.item$*5 ------ <ul> <li class="item1"></li> <li class="item2"></li> <li class="item3"></li> <li class="item4"></li> <li class="item5"></li> </ul>
ul>li.item$$*5 ------ <ul> <li class="item001"></li> <li class="item002"></li> <li class="item003"></li> <li class="item004"></li> <li class="item005"></li> </ul>
ul>li.item$@-*5 ------ <ul> <li class="item5"></li> <li class="item4"></li> <li class="item3"></li> <li class="item2"></li> <li class="item1"></li> </ul>
ul>li.item$@3*5 ------ <ul> <li class="item3"></li> <li class="item4"></li> <li class="item5"></li> <li class="item6"></li> <li class="item7"></li> </ul>
ul>li.item$@-3*5 ------ <ul> <li class="item7"></li> <li class="item6"></li> <li class="item5"></li> <li class="item4"></li> <li class="item3"></li> </ul>
內容:{ }
a{Click me} ------ <a href="">Click me</a>
p>{Click }+a{here}+{ to continue} ------ <p>Click <a href="">here</a> to continue</p>
ID and Class
div#header+div.page+div#footer.class1.class2.class3 ------ <div id="header"></div> <div class="page"></div> <div id="footer" class="class1 class2 class3"></div>
自訂屬性
td[title="Hello world!" colspan=3] ------ <td title="Hello world!" colspan="3"></td>
giovmar fe9c53e484 https://coub.com/stories/4909118-descargar-wolf-of-the-mountain-version-pirateada
nanoroz baf94a4655 https://trello.com/c/H9lsB8fS/70-descargar-think-to-die-versi%C3%B3n-pirateada
leonshai baf94a4655 https://trello.com/c/ijYmF3CT/60-rules-of-gravity-versi%C3%B3n-completa
eregemm baf94a4655 https://www.guilded.gg/verferincis-Rams/overview/news/X6Q1d1g6
kaffilyn baf94a4655 https://coub.com/stories/4903583-descargar-revulsion-version-pirateada
You got a very superb website, Glad I discovered it through yahoo.
gefflit baf94a4655 https://coub.com/stories/4932475-descargar-ul-version-completa
hiaans baf94a4655 https://trello.com/c/UKAzWedG/38-ul-gratuita-2021
I’d perpetually want to be update on new posts on this site, saved to bookmarks! .
kalageo baf94a4655 https://trello.com/c/9Ao5Lf24/116-grave-complex-versi%C3%B3n-completa-2021
ugansatu baf94a4655 https://coub.com/stories/4960309-descargar-drainlive-version-completa
Very interesting information!Perfect just what I was searching for!
reimar baf94a4655 https://trello.com/c/0GV1mKzA/105-descargar-douarnenez-vr-gratuita
garmnanc baf94a4655 https://coub.com/stories/4944995-descargar-srx-the-game-version-completa
colcepi baf94a4655 https://coub.com/stories/4947404-descargar-the-hong-kong-massacre-version-pirateada
meacla baf94a4655 https://coub.com/stories/4904960-corgi-warlock-version-completa-2022
dalwin baf94a4655 https://www.guilded.gg/psychececals-Lightning/overview/news/dl7r2mmR
feltwak baf94a4655 https://coub.com/stories/4941904-descargar-unfair-gratuita
laundum baf94a4655 https://www.guilded.gg/jingcoweerus-Dodgers/overview/news/9yWje3N6
furmderr baf94a4655 https://trello.com/c/ySPro9Rz/57-descargar-obduction-versi%C3%B3n-completa-gratuita
terrfond baf94a4655 https://www.guilded.gg/gastsenseequars-Squad/overview/news/QlL1n8P6
visisal baf94a4655 https://coub.com/stories/4947064-descargar-small-ball-version-pirateada
ikaiqad baf94a4655 https://coub.com/stories/4958191-descargar-ul-gratuita
latoanto baf94a4655 https://trello.com/c/nDrJDrUb/78-cowboy-escape-versi%C3%B3n-completa
sauwale baf94a4655 https://www.guilded.gg/quiswanermans-Red-Sox/overview/news/dlv9AEBR
santal baf94a4655 https://marketplace.visualstudio.com/items?itemName=oposra-wo.Descargar-Mostly-Scared-Of-Spiders-gratuita
verlit baf94a4655 https://trello.com/c/7v2wib7G/83-descargar-what-are-you-stupid-versi%C3%B3n-completa-2021
immwai baf94a4655 https://coub.com/stories/4922106-descargar-surgeon-simulator-2-version-completa-2022
tarypen baf94a4655 https://coub.com/stories/4950705-the-chronicles-of-joseph-of-egypt-version-completa
hargol baf94a4655 https://coub.com/stories/4920548-descargar-our-love-will-grow-gratuita-2021