-
Notifications
You must be signed in to change notification settings - Fork 10.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Combine Array.from
and Array.prototype.map
calls
#15637
Conversation
This isn't just a tiny bit more compact, but it also avoids an intermediate allocation; please see https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/from#description
/botio test |
From: Bot.io (Linux m4)ReceivedCommand cmd_test from @Snuffleupagus received. Current queue size: 0 Live output at: http://54.241.84.105:8877/c10e5bf6559e116/output.txt |
From: Bot.io (Windows)ReceivedCommand cmd_test from @Snuffleupagus received. Current queue size: 0 Live output at: http://54.193.163.58:8877/56ddc7626258034/output.txt |
From: Bot.io (Linux m4)FailedFull output at http://54.241.84.105:8877/c10e5bf6559e116/output.txt Total script time: 25.57 mins
Image differences available at: http://54.241.84.105:8877/c10e5bf6559e116/reftest-analyzer.html#web=eq.log |
From: Bot.io (Windows)FailedFull output at http://54.193.163.58:8877/56ddc7626258034/output.txt Total script time: 26.56 mins
|
/botio-windows integrationtest |
From: Bot.io (Windows)ReceivedCommand cmd_integrationtest from @Snuffleupagus received. Current queue size: 0 Live output at: http://54.193.163.58:8877/7f25c261b072334/output.txt |
From: Bot.io (Windows)FailedFull output at http://54.193.163.58:8877/7f25c261b072334/output.txt Total script time: 9.70 mins
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM.
Could we have a linting rule for that ?
Unfortunately I've not found any existing plugin for this, and I don't really have the knowledge/time to implement a custom ESLint plugin for this. |
This isn't just a tiny bit more compact, but it also avoids an intermediate allocation; please see https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/from#description