> * `Function.empty` - a standard empty function that can be used when you just 
> want an empty function (IMHO, it indicates intent much better than other 
> options toda).

Ironically, that’s what Function.prototype is. But using that object in that 
capacity is beyond confusing. I’d prefer a different name such as “noop” or 
“doNothing”; “empty” doesn’t feel right in the context of something executable.

Also, I don’t find using an empty arrow function too bad (to me, it looks quite 
intention-revealing):

```js
someAsyncMethod(() => {});
```

-- 
Dr. Axel Rauschmayer
[email protected]
rauschma.de



_______________________________________________
es-discuss mailing list
[email protected]
https://mail.mozilla.org/listinfo/es-discuss

Reply via email to