W3C home > Mailing lists > Public > public-css-archive@w3.org > October 2017

Re: [csswg-drafts] [css-selectors] nth-child produces a local variable

From: Oriol Brufau via GitHub <sysbot+gh@w3.org>
Date: Sat, 14 Oct 2017 17:28:02 +0000
To: public-css-archive@w3.org
Message-ID: <issue_comment.created-336650532-1508002066-sysbot+gh@w3.org>
I think allowing [`counter()`](https://drafts.csswg.org/css-lists/#counter-functions) to return an integer would be a better way to address this kind of problems.

```css
.foobar {
  counter-reset: n;
}
.foobar > * {
  counter-increment: n;
  grid-row: counter(n integer);
}
```

-- 
GitHub Notification of comment by Loirooriol
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/1869#issuecomment-336650532 using your GitHub account
Received on Saturday, 14 October 2017 17:27:50 UTC

This archive was generated by hypermail 2.4.0 : Tuesday, 5 July 2022 06:41:19 UTC