-
Notifications
You must be signed in to change notification settings - Fork 10.3k
Enable the unicorn/no-array-push-push
ESLint plugin rule
#13435
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
Enable the unicorn/no-array-push-push
ESLint plugin rule
#13435
Conversation
There's generally speaking no need to use multiple consecutive `Array.prototype.push()` calls, since that method accepts multiple arguments, and this ESLint rule helps enforce that pattern. Please see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/main/docs/rules/no-array-push-push.md for additional information.
/botio lint |
From: Bot.io (Windows)ReceivedCommand cmd_lint from @Snuffleupagus received. Current queue size: 0 Live output at: http://3.101.106.178:8877/c156c37ef1b7baf/output.txt |
From: Bot.io (Linux m4)ReceivedCommand cmd_lint from @Snuffleupagus received. Current queue size: 0 Live output at: http://54.67.70.0:8877/0c7ca76bd6a3601/output.txt |
From: Bot.io (Linux m4)FailedFull output at http://54.67.70.0:8877/0c7ca76bd6a3601/output.txt Total script time: 0.00 mins |
From: Bot.io (Windows)SuccessFull output at http://3.101.106.178:8877/c156c37ef1b7baf/output.txt Total script time: 4.03 mins
|
/botio test |
From: Bot.io (Linux m4)ReceivedCommand cmd_test from @timvandermeij received. Current queue size: 0 Live output at: http://54.67.70.0:8877/ff8356005fe1368/output.txt |
From: Bot.io (Windows)ReceivedCommand cmd_test from @timvandermeij received. Current queue size: 1 Live output at: http://3.101.106.178:8877/102e255a7ad7813/output.txt |
From: Bot.io (Linux m4)FailedFull output at http://54.67.70.0:8877/ff8356005fe1368/output.txt Total script time: 26.01 mins
Image differences available at: http://54.67.70.0:8877/ff8356005fe1368/reftest-analyzer.html#web=eq.log |
From: Bot.io (Windows)FailedFull output at http://3.101.106.178:8877/102e255a7ad7813/output.txt Total script time: 30.01 mins
Image differences available at: http://3.101.106.178:8877/102e255a7ad7813/reftest-analyzer.html#web=eq.log |
This looks like a nice addition to me; thank you! |
There's generally speaking no need to use multiple consecutive
Array.prototype.push()
calls, since that method accepts multiple arguments, and this ESLint rule helps enforce that pattern.Please see https://github.com/sindresorhus/eslint-plugin-unicorn/blob/main/docs/rules/no-array-push-push.md for additional information.