Re: Domain selectors

> As an alternative selector syntax for your purpose, a function could be used
> instead of the attribute-selector syntax you've proposed:
>
>     ::domain("example.com") .foo {
>         /* Domain-specific styles for elements
>            with the `foo` class. */
>     }
>
> But this does not seem to have serious advantages (other than just
> somewhat simpler syntax thanks to less braces) over an at-rule like
> `@document`:
>
>     @document domain("example.com") {
>         .foo {
>             /* Domain-specific styles for elements
>                with the `foo` class. */
>         }
>     }

I’d prefer ::domain over @document, but I’d wish we pushed harder for
simplicity. Hence, is that all as simple as we could get it? Why would
[host=] (or domain, document, or perhaps url) be so objectionable?

-- 
Jens Oliver Meiert
http://meiert.com/en/

✎ The Little Book of HTML/CSS Frameworks: http://meiert.com/frameworks

Received on Monday, 9 March 2015 19:14:54 UTC