- From: Marek Pawlowski <marekp.w3c@gmail.com>
- Date: Wed, 5 Sep 2007 22:42:45 +0200
- To: "Ian Hickson" <ian@hixie.ch>
- Cc: public-html@w3.org
On 2007/9/5, Ian Hickson <ian@hixie.ch> wrote: > Wouldn't: > > with (myDiv.classList) { > add('toFront'); > toggle('maximized'); > } > > ...be the better way to do this? In general the DOM doesn't do > chaining-style APIs, so I'm reluctant to add it here. As far as I remember, use of "with" statement is discouraged due to performance problems in existing implementations. Anyway there is good use case for function chaining in current Javascript frameworks like jQuery and IIRC prototype.js with some extensions. But it's just came to my mind; I wont zealously fight for this :) -- Regards, Marek Pawłowski
Received on Wednesday, 5 September 2007 20:42:51 UTC