Back to Serenity

:nth

Base/res/html/misc/nth-child.html

latest885 B
Original Source

:nth-child(odd)

1 +

2

3 +

4

:nth-child(2n+1) - same as odd

1 +

2

3 +

4

:nth-child(even)

1

2 +

3

4 +

:nth-child(2n) - same as even

1

2 +

3

4 +

:nth-child(2)

1

2 +

3

:nth-child(3n)

1

2

3 +

4

5

6 +

:nth-child(3n+1)

1 +

2

3

4 +

5

6

:nth-child(3n-1)

1

2 +

3

4

5 +

6

:nth-child(-n+3)

1 +

2 +

3 +

4

:nth-child(n)

1 +

2 +

3 +

:nth-child(-n) - same as n

1 +

2 +

3 +

:nth-child(+n) - same as n

1 +

2 +

3 +

:nth-child(0n+1)

1 +

2

3

:nth-child(n+2):nth-child(-n+4)

1

2 +

3 +

4 +

5

:nth-child(-5n+3) - Acid3

1

2

3 +

4

5

6

7

8

9

10

11

12

13

14

15

:nth-child(2n of div)

1

Paragraph

2 +

Paragraph

3

Paragraph

4 +

Paragraph

5

Paragraph

6 +

Paragraph

:nth-child(3n+1 of .special)

1 +

2

(Ignored)

3

(Ignored)

4 +