Richie
Richie

Reputation: 41

Better way to organize multiple CSS code?

In my CSS code, I have this:

#feed .post:hover .rep {display:inline;}
#feed .post:hover .com {display:inline;}
#feed .post:hover .date {display:inline;}

Is there a way I could make it so rather than being 3 lines, it's all in one line? I tried doing

#feed .post:hover .rep, .com, .date {display:inline;}

But that didn't seem to work. Thanks.

Upvotes: 0

Views: 49

Answers (1)

Mat Richardson
Mat Richardson

Reputation: 3606

This should do it:-

#feed .post:hover .rep, #feed .post:hover .com, #feed .post:hover .date {display: inline}

Upvotes: 1

Related Questions