inline-css icon indicating copy to clipboard operation
inline-css copied to clipboard

Add sortAlphabetically option

Open dakur opened this issue 7 years ago • 4 comments

I would appreciate adding of sortAlphabetically option, which would be set to true in default (to be compatible with older versions). That's because I need special CSS attributes for older IEs starting with underscore to be defined after their standard relatives, but inline-css sorts them before their standard relatives. That means the standard attribute overwrites its behaviour.

Before inlining:

div {
    width: auto;
    _width: 230px;
}

After inlining:

<div style="_width:230px;width:auto;">...</div>

which means that even in old IEs 230px is overwritten by auto.

dakur avatar Mar 30 '17 12:03 dakur

Hey, I think, that for now everything is sorted alphabetically, am I correct?

That causes big issue - I have one element, let's say table.content and styles for table in some general css file: table {margin-top: 100px;} and in my personal css file rule for table.content { margin: 0 ;}. After bundling and inlining those style sheets, styles for table comes after styles for table.content, so in the resulting HTML the table has 100px margin top (which is against css specificity).

I think that is a major bug...

kazagkazag avatar Jul 24 '17 12:07 kazagkazag

+1

KimDal-hyeong avatar Sep 21 '17 09:09 KimDal-hyeong

+1

leopoiroux avatar Nov 14 '17 22:11 leopoiroux

+1

dudeonthehorse avatar Nov 26 '17 00:11 dudeonthehorse