Skip to main content
Module

x/lru/mod.ts>default#map

Simple and powerful LRU cache for Deno
Latest
method default.prototype.map
import { default } from "https://deno.land/x/lru@1.0.2/mod.ts";

Method creates a new array populated with the results of calling a provided function on every element in the calling array

Parameters

callbackfn: (
value: [string, T],
index: number,
array: [string, T][],
) => T

Function that is called for every element of arr. Each time callback executes, the returned value is added to new_array

optional
thisArg: unknown

Value to use as this when executing callback