内容简介:Have you ever found yourself either writing a CSS selector that winds up looking confusing as heck, or seen one while reading through someone's code? That happened to me the other day.Here's what I wrote:At the end of it, I honestly couldn't even explain w
Have you ever found yourself either writing a CSS selector that winds up looking confusing as heck, or seen one while reading through someone's code? That happened to me the other day.
Here's what I wrote:
.site-footer__nav a:hover > svg ellipse:first-child { }
At the end of it, I honestly couldn't even explain what it does to myself. LOL, that probably means there was a better way to write it.
But Hugo Giraudel has this handy new tool that will explain any selector you throw at it.
Here's how it explained mine:
An <ellipse>
element provided it is the first child of its parent somewhere
… within a <svg>
element
… itself directly within an <a>
element provided it is hovered
… itself somewhere
… within an element with class site-footer__nav
.
Bravo! It even spits out the specificity of the selector to boot.
Direct Link to Article — Permalink
The post Selectors Explained appeared first on CSS-Tricks .
以上就是本文的全部内容,希望本文的内容对大家的学习或者工作能带来一定的帮助,也希望大家多多支持 码农网
猜你喜欢:本站部分资源来源于网络,本站转载出于传递更多信息之目的,版权归原作者或者来源机构所有,如转载稿涉及版权问题,请联系我们。
算法设计与分析基础
Anany levitin / 潘彦 / 清华大学出版社 / 2007-1-1 / 49.00元
作者基于丰富的教学经验,开发了一套对算法进行分类的新方法。这套方法站在通用问题求解策略的高度,能对现有的大多数算法都能进行准确分类,从而使本书的读者能够沿着一条清晰的、一致的、连贯的思路来探索算法设计与分析这一迷人领域。本书作为第2版,相对第1版增加了新的习题,还增加了“迭代改进”一章,使得原来的分类方法更加完善。 本书十分适合作为算法设计和分析的基础教材,也适合任何有兴趣探究算法奥秘的读者......一起来看看 《算法设计与分析基础》 这本书的介绍吧!