You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I noticed that the Web Speech API is defining new *List and list-like types:
SpeechRecognitionResult
SpeechRecognitionResultList
And more...
They are "array/list-like" in that they have a .length, an index accessor, and so on, but are actually incompatible with the ES iterator protocol (and violate the "give things constructors principle").
We should probably provide guidance against defining new list types for the platform, and instead rely on WebIDL iterable (or setlike, tho that's rare I believe).
The text was updated successfully, but these errors were encountered:
Sure, it’s more to catch APIs developed in isolation (in the off chance they also land at this guide). We can’t keep an eye on everything, unfortunately.
I noticed that the Web Speech API is defining new
*List
and list-like types:SpeechRecognitionResult
SpeechRecognitionResultList
They are "array/list-like" in that they have a
.length
, an index accessor, and so on, but are actually incompatible with the ES iterator protocol (and violate the "give things constructors principle").We should probably provide guidance against defining new list types for the platform, and instead rely on WebIDL
iterable
(or setlike, tho that's rare I believe).The text was updated successfully, but these errors were encountered: