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
The issue is that Object.keys does not guarantee it's returning a non-empty array. For example,
lens.props(...Object.keys({})) would be lens.props() which makes no sense.
Another issue is that Object.keys does not guarantee order. So you can't even be sure that your arguments are being passed in in the correct order.
One implementation of Object.keys({foo:'',bar:''}) might return ['foo','bar'] while another might return ['bar','foo']. So even if it works for you right now, there is no guarantee that it will continue to work, or will even work with another JavaScript implementation in another browser or a different version of Node, because the ECMA spec does not require Object.keys to return keys in any specific order.
So I'm not even sure you're right when you say your code is "correct."
I understand it's a helpful API, but in my general form library I have this code:
Which is correct I suppose, but I got
Expected at least 2 arguments, but got 0 or more.
The text was updated successfully, but these errors were encountered: