html - Repeated Rules in Element's CSS -
i have client has existing blog through squarespace. taking on website, , coming across code have never seen before. have issue fonts rendering correctly across browsers. when inspect elements in question, find strange css code. have noticed on many elements such h1, there repeated rules in css. see below example:
#topnav nav, #topnav ul, #topnav li, #topnav { font-family: georgia,serif; font-weight: normal; font-style: italic; line-height: 1.6em; font-size: 13px; text-transform: normal; letter-spacing: 0px; font-family: "helvetica neue","arial","sans-serif"; font-size: 30px; line-height: 4em; text-transform: capitalize; text-decoration: none; letter-spacing: -1px; font-weight: bold; font-style: normal; } as can see, there several repeated rules. consequences of css code? cause code styled differently on different browsers?
this extremely large website, hoping wasn't habit of last developer code this. should cleaning styles top priority? opinions fantastic!
thanks!
i have poor coding. impact on rendering, think last instance of style take precedence since whole nature of css "cascading" inheritance.
a simple experiment or 2 should yield answer question.
Comments
Post a Comment