Skip to content

merge different selectors with similar properties  #27

@yairEO

Description

@yairEO

Turn this:

a{ color:red; opacity:1; background:blue; }
b{ color:red; opacity:1; background:blue; height:10px; }

To this:

a,b{ color:red; opacity:1; background:blue; }
b{ height:10px; }

But only if it's "worth it" meaning, bytes were saved. in some situations the selector might be too long and not worth it:

a{ color:red; opacity:1; background:blue; }
.this_is_a_very > .long_selector ~ ul.drop_down_selector > li.list_item b{ color:red; opacity:1; background:blue; }

in the above example it's not worth repeating that long selector again, just to merge it's properties with a selector. it would result in a larger output.

This would eliminate the need to use extend methods in pre-processors manually and ease the workflow.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions