stuartpb / cre

A better way to construct DOM nodes.
MIT License
10 stars 1 forks source link

More advanced selector magic #5

Open stuartpb opened 8 years ago

stuartpb commented 8 years ago

Stuff I'm thinking about:

stuartpb commented 1 year ago

Thinking about this a little bit: if you're creating a "nested element":

Seeing as how my gut answer for the first question is "the last one" and the last question is "the first one", I think these considerations are lopsided enough that I'd leave nested-element creation to nested cre calls.

stuartpb commented 1 year ago

As for prop="val"... I don't know that I want opts and the initial string to both be able to set props (ie. which one takes precedence in a conflict?) But I could maybe be persuaded if a compelling-enough case (ie. more compelling than, say, a ternary operator that switches property values in the initial element selector string) were suggested.