Socket
Socket
Sign inDemoInstall

is-arguments

Package Overview
Dependencies
0
Maintainers
1
Versions
8
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    is-arguments

Is this an arguments object? It's a harder question than you think.


Version published
Weekly downloads
21M
decreased by-7.84%
Maintainers
1
Install size
13.5 kB
Created
Weekly downloads
 

Package description

What is is-arguments?

The is-arguments npm package is designed to check if a given value is an arguments object. This can be particularly useful in functions where you need to differentiate between an array and the arguments object, or when trying to ensure compatibility across different JavaScript environments where the typeof operator might not suffice.

What are is-arguments's main functionalities?

Check if a value is an arguments object

This feature allows you to check if a given value is an arguments object. It's particularly useful in scenarios where you need to distinguish between an array and the arguments object passed to a function.

const isArguments = require('is-arguments');

function example() {
  console.log(isArguments(arguments)); // true
  console.log(isArguments([1, 2, 3])); // false
}

example();

Other packages similar to is-arguments

Changelog

Source

v1.0.1 - 2015-04-29

Commits

  • Update jscs, add npm run eslint 13a5f01
  • Using my standard jscs.json file d669fc4
  • Adding npm run lint ece5d05
  • Test on latest io.js 908b092
  • Adding license and downloads badges 05fd28b
  • Make sure old and unstable nodes don't break Travis 16ee7ea
  • All grade A-supported node/iojs versions now ship with an npm that understands ^. 9846c79
  • Run travis-ci tests on iojs and node v0.12; speed up builds; allow 0.8 failures. 27c014d
  • Use SVG instead of PNG badges ea01e68
  • Remove unused links in README f5baaff
  • Test on latest io.js versions 293e2c4
  • Update tape, jscs d72ab08
  • Update jscs 5f6e6d4
  • Update tape, jscs 39ae55b
  • Update tape, jscs 594d928
  • Updating dependencies 183ac15
  • Update tape 77b9cea
  • Lock covert to v1.0.0. 28d9052
  • Updating tape d9ee2ac
  • Updating jscs c0cab8f
  • Updating jscs c59352a
  • Run linter as part of tests 8b8154e
  • Oops, properly running code coverage checks during tests. cc441d0
  • Updating covert. 142db90
  • Updating tape 265fd0f
  • Updating tape 7e9aec6
  • Updating covert d96860a
  • Updating tape 1ec32a0
  • Run code coverage as part of tests 155ab22
  • Coverage does not work currently on node 0.6. 9acf696
  • Testing node 0.6 again a23ca07

Readme

Source

#is-arguments Version Badge

Build Status dependency status dev dependency status License Downloads

npm badge

browser support

Is this an arguments object? It's a harder question than you think.

Example

var isArguments = require('is-arguments');
var assert = require('assert');

assert.equal(isArguments({}), false);
assert.equal(isArguments([]), false);
(function () {
	assert.equal(isArguments(arguments), true);
}())

Tests

Simply clone the repo, npm install, and run npm test

Keywords

FAQs

Last updated on 29 Apr 2015

Did you know?

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

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc