Research
Recent Trends in Malicious Packages Targeting Discord
The Socket research team breaks down a sampling of malicious packages that download and execute files, among other suspicious behaviors, targeting the popular Discord platform.
argsbytype
Advanced tools
Changelog
v3.21.0 2020 October 29
Readme
Provide some arguments, get back a hash object of the arguments indexed by their type. Very useful for agnostic argument orders.
Let's say your coding a function, and you want to accept arguments in any order. Traditionally this would look like:
https://github.com/bevry/argsbytype/blob/master/example/01.js
But what happens when you:
typeof
is still object
instead of regexp
or date
name
property, the second string should be the keyword
property)At that point in time, it becomes too much trouble to bother with. Fortunately, argsbytype
is to the rescue! Now you can do:
https://github.com/bevry/argsbytype/blob/master/example/02.js
Yay! Big win for agnostic argument order! But when would you actually want this? Well, it turns out that in CoffeeScript options come first, in JavaScript, options usually come last. By using this, we can support both conventions, for example:
https://github.com/bevry/argsbytype/blob/master/example/03.js
npm install --save argsbytype
import * as pkg from ('argsbytype')
const pkg = require('argsbytype')
<script type="module">
import * as pkg from '//dev.jspm.io/argsbytype@3.21.0'
</script>
This package is published with the following editions:
argsbytype
aliases argsbytype/source/index.js
argsbytype/source/index.js
is ESNext source code for Node.js 10 || 12 || 14 || 15 with Require for modulesargsbytype/edition-browsers/index.js
is ESNext compiled for web browsers with Require for modulesDiscover the release history by heading on over to the HISTORY.md
file.
Discover how you can contribute by heading on over to the CONTRIBUTING.md
file.
These amazing people are maintaining this project:
No sponsors yet! Will you be the first?
These amazing people have contributed code to this project:
Discover how you can contribute by heading on over to the CONTRIBUTING.md
file.
Unless stated otherwise all works are:
and licensed under:
FAQs
Provide some arguments, get back a hash object of the arguments indexed by their type. Very useful for agnostic argument orders.
The npm package argsbytype receives a total of 0 weekly downloads. As such, argsbytype popularity was classified as not popular.
We found that argsbytype demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 2 open source maintainers collaborating on the project.
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.
Research
The Socket research team breaks down a sampling of malicious packages that download and execute files, among other suspicious behaviors, targeting the popular Discord platform.
Security News
Socket CEO Feross Aboukhadijeh joins a16z partners to discuss how modern, sophisticated supply chain attacks require AI-driven defenses and explore the challenges and solutions in leveraging AI for threat detection early in the development life cycle.
Security News
NIST's new AI Risk Management Framework aims to enhance the security and reliability of generative AI systems and address the unique challenges of malicious AI exploits.