Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@putout/plugin-convert-arguments-to-rest

Package Overview
Dependencies
Maintainers
1
Versions
9
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@putout/plugin-convert-arguments-to-rest

🐊Putout plugin adds ability to convert arguments to rest

  • 3.1.0
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
1
Created
Source

@putout/plugin-convert-arguments-to-rest NPM version

The rest parameter syntax allows a function to accept an indefinite number of arguments as an array, providing a way to represent variadic functions in JavaScript.

(c) MDN

🐊Putout plugin adds ability to convert arguments to rest.

Install

npm i @putout/plugin-convert-arguments-to-rest -D

Rule

{
    "rules": {
        "convert-arguments-to-rest": "on"
    }
}

❌ Example of incorrect code

function hello() {
    console.log(arguments);
}

✅ Example of correct code

function hello(...args) {
    console.log(args);
}

License

MIT

Keywords

FAQs

Package last updated on 27 Sep 2024

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc