W3C home > Mailing lists > Public > public-fxtf-archive@w3.org > June 2019

Re: [fxtf-drafts] [geometry] DOMMatrix constructor is a performance and code portability footgun (#346)

From: Tab Atkins Jr. via GitHub <sysbot+gh@w3.org>
Date: Thu, 27 Jun 2019 23:09:15 +0000
To: public-fxtf-archive@w3.org
Message-ID: <issue_comment.created-506542721-1561676954-sysbot+gh@w3.org>
Ah, right! Thanks for digging up those references!

Okay, so it looks like we were just a bit overzealous here, then; we were already mentally committed to having the constructor take a DOMMatrixInit (which you can't distinguish from any other object), and so moved the entire chunk of argument-space over to a static method. Whereas we *could* have left DOMMatrixReadonly in the constructor's union, satisfying bz's concern in this thread and still fixing the original problem.

That would just mean that you could pass a literal DOMMatrix *either* in the constructor *or* the `.fromMatrix()` method and get the same result, but that seems fine.

GitHub Notification of comment by tabatkins
Please view or discuss this issue at https://github.com/w3c/fxtf-drafts/issues/346#issuecomment-506542721 using your GitHub account
Received on Thursday, 27 June 2019 23:09:17 UTC

This archive was generated by hypermail 2.3.1 : Thursday, 27 June 2019 23:09:18 UTC