Re: [dom] Is it recommended to use Node.getFeature() or Node.isSupported()?

On Wed, Aug 21, 2013 at 5:56 PM, Boris Zbarsky <bzbarsky@mit.edu> wrote:
> On 8/21/13 8:43 PM, James Craig wrote:
>>
>> if (typeof document.body.ondismissrequest !== "undefined") {
>
>
> Just if ("ondismissrequest" in document.body), I'd think.

Yeah, this is all you need to do.  It's not perfect, but web devs are
good at making a racket when we accidentally ship something that
passes this test but doesn't actually work.

~TJ

Received on Thursday, 22 August 2013 02:12:06 UTC