I'm trying to address all the div
, table
, ul
, dl
, etc. children of a selector using LESS.
I would love to write something like this.
.myclass {
...
&.otherClass > (div, ul, dl, table) {
// define some rules...
}
}
I would expect the following output.
.myclass.otherClass > div,
.myclass.otherClass > ul,
.myclass.otherClass > dl,
.myclass.otherClass > table {
// rules
}
But the parenthesis seems like not supported, as it compiles as is, resulting an invalid CSS of course.
Is there any syntax or other way to have such a shortcut in definitions?