Skip to main content
Using Deno in production at your company? Earn free Deno merch.
Give us feedback
Module

x/denocordts/deps.ts>Collection#tap

An Object Oriented Discord API wrapper for Deno.
Latest
method Collection.prototype.tap
import { Collection } from "https://deno.land/x/denocordts@1.2.0/deps.ts";

Runs a function on the collection and returns the collection.

Examples

collection .tap(coll => console.log(coll.size)) .filter(user => user.bot) .tap(coll => console.log(coll.size))

Parameters

fn: (collection: this) => void

Function to execute

Parameters

fn: (this: T, collection: this) => void
thisArg: T