[whatwg] [canvas] Path object
ian at hixie.ch
Tue Oct 9 11:43:10 PDT 2012
On Tue, 9 Oct 2012, Anne van Kesteren wrote:
> On Tue, Oct 9, 2012 at 1:29 AM, Ian Hickson <ian at hixie.ch> wrote:
> > We could only change Path, since the others are already deployed. We
> > could add new constructors, but that would just be new redundancy, and
> > thus probably isn't worth it.
> FWIW, I think adding new constructors to make things more convenient for
> authors can definitely be worth it. E.g. I'm strongly considering adding
> new Document() so you no longer need
> document.implementation.createDocument(..., ..., ...). Similarly we
> already added new Event() and friends to substantially improve the
> custom events situation.
For new features I completely agree, but for old features we have to be
really careful about not adding redundancy, IMHO. Events are used quite a
lot and the new constructors did much more than just make the API
consistent -- it also made it way simpler, to the point where what was
three lines of code with dozens of ambiguous arguments is now a single
line of very readable code. With the canvas objects it's not at all clear
to me that we'd get the same win.
Ian Hickson U+1047E )\._.,--....,'``. fL
http://ln.hixie.ch/ U+263A /, _.. \ _\ ;`._ ,.
Things that are impossible just take longer. `._.-(,_..'--(,_..'`-.;.'
More information about the whatwg