Supporting feature tests directly
andrea.giammarchi at gmail.com
Wed Mar 25 19:06:52 UTC 2015
For consistency sake I agree, but I come from a world where browsers also
exposed unofficially APIs so that, as James mentioned already, `
Array.prototype.includes` would have returned true and never worked.
I wonder how reliable is `CSS.supports` not just in term of syntax, but
On Wed, Mar 25, 2015 at 7:44 PM, Tab Atkins Jr. <jackalmage at gmail.com>
> On Sun, Mar 22, 2015 at 3:59 AM, Andrea Giammarchi
> <andrea.giammarchi at gmail.com> wrote:
> > +1 to Kyle proposal, using eval or Function is not even an option in CSP
> > constrained environments ( unless the relative code is provided as
> > then we need to agree on how such code should look like and share it as
> > polyfill )
> > I'd also suggest `Reflect.isValidSyntax` as alternative to
> > `Reflect.supports` 'cause it's less misleading when it comes to figure
> > APIs support and their implementation.
> > After all, that's exactly what we'd like to know, if a generic syntax
> > break or not.
> CSS has an exactly analogous feature already, and calls it
> CSS.supports(). That's a decent reason to stick with supports() as
> the name.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the es-discuss