Closed aawwawa closed 11 years ago
I think jQuery might do some clever detective work on the element type you're operating with to see what display
property it needs, given the current stylesheet rules. We had a discussion (somewhere in here) about it when the argument was added to type
, I think the conclusion was that it's way too much overhead (in terms of complexity and code weight) to do something similar in Bonzo (for now anyway).
However, storing the previous value of display
for an element probably wouldn't add too much overhead. Could probably use data()
storage safely enough. I guess it's purely a question of merit.
implementing it would be fairly straight forward, but considering you can already do display('inline')
— you should be alright
It isn't a matter of "alright," I feel like it's a matter of ease of use and elegance.
this issue came up (probably 3 other times) in the early days, and they were each closed. considering the amount of detection & guess work this would take, i don't feel the amount of code to get this to be full proof isn't worth it. especially considering you can just pass in the type...
Can't remember, but jQuery might do this. In any case, it would make for more predictable behavior. I'm just not badass enough to be able to implement it.