New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

apr-map

Package Overview
Dependencies
Maintainers
1
Versions
10
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

apr-map - npm Package Compare versions

Comparing version 1.0.1 to 1.0.2

readme.md

27

index.js
const run = require('./run');
/**
* <a id="map"></a>
* Produces a new collection of values by mapping each value in `coll` through the `iteratee` function.
*
* [![](https://img.shields.io/npm/v/apr-map.svg?style=flat-square)](https://www.npmjs.com/package/apr-map) [![](https://img.shields.io/npm/l/apr-map.svg?style=flat-square)](https://www.npmjs.com/package/apr-map)
*
* @kind function
* @name map
* @param {Array|Object|Iterable} input
* @param {Function} iteratee
* @returns {Promise}
*
* @example
* import awaitify from 'apr-awaitify';
* import map from 'apr-map';
*
* const stat = awaitify(fs.stat);
* const files = [
* 'file1',
* 'file2',
* 'file3'
* ];
*
* const stats = await map(files, async (file) =>
* await stat(file);
* );
*/
module.exports = (input, fn, opts) => {

@@ -4,0 +31,0 @@ return run({

10

limit.js
const defaults = require('lodash.defaults');
const run = require('./run');
/**
* @kind function
* @name limit
* @memberof map
* @param {Array|Object|Iterable} input
* @param {Number} limit
* @param {Function} iteratee
* @returns {Promise}
*/
module.exports = (input, limit, fn, opts) => {

@@ -6,0 +14,0 @@ return run({

2

package.json
{
"name": "apr-map",
"version": "1.0.1",
"version": "1.0.2",
"description": "",

@@ -5,0 +5,0 @@ "keywords": [],

const limit = require('./limit');
/**
* @kind function
* @name series
* @memberof map
* @param {Array|Object|Iterable} input
* @param {Function} iteratee
* @returns {Promise}
*/
module.exports = (input, fn, opts) => {
return limit(input, 1, fn, opts);
};
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