W3C home > Mailing lists > Public > public-script-coord@w3.org > October to December 2011

[WebIDL] Remove string constants

From: Anne van Kesteren <annevk@opera.com>
Date: Thu, 20 Oct 2011 11:25:57 +0900
To: public-script-coord@w3.org
Message-ID: <op.v3moz7o464w2qv@annevk-macbookpro.local>
Strings are intrinsically meaningful and therefore have no need for  
constants in APIs for the platform. See XMLHttpRequest.responseType and  
the <canvas> 2D API for examples. We should remove string constants so  
people (e.g. public-web-perf) will not use them and introduce inconsistent  
APIs.

We should probably also strongly deprecate numerical constants, maybe even  
go as far as naming them "legacyconstant", since they are generally  
considered a poor API too and where it makes sense we have moved away from  
them (e.g. with exceptions).


-- 
Anne van Kesteren
http://annevankesteren.nl/
Received on Thursday, 20 October 2011 02:26:34 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 8 May 2013 19:30:04 UTC