禅宗编码的父选择器 [英] Parent selector for zen-coding
本文介绍了禅宗编码的父选择器的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我刚刚发现了禅宗编码.
I just discovered zen-coding.
我有以下要生成的代码片段.
I have the following snippet of code I want to generate.
<div id="base">
<div id="header">
<div id="logo"></div>
</div>
<div id="body"></div>
<div id="footer"></div>
</div>
有没有办法用一行禅宗代码做到这一点
Is there a way to do this with one line of zen-code
我知道我会写
div#base>div#header>div#logo
这是我卡住的地方,因为我不知道如何返回并添加正文和页脚div(页眉的兄弟姐妹).
this is where I get stuck, cause I don't know, how I can go back and add body and footer divs(siblings of header).
我想弄清楚是否/如何在一行中完成此操作.
I want to figure out if/how this can be done in one line.
谢谢!:)
推荐答案
这与适用于Notepad ++的ZenCoding对我有用
This works for me with ZenCoding for Notepad++
div#base>(div#header>div#logo)+div#body+div#footer
这篇关于禅宗编码的父选择器的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文