External module "node_modules/@slack/client/dist/util.d"
Type aliases
AgentOption
Agent
Option: Agent | object | boolean
Variables
Const callbackify
Functions
addAppMetadata
- addAppMetadata(__namedParameters: object): void
-
Parameters
-
__namedParameters: object
-
name: string
-
version: string
Returns void
agentForScheme
- agentForScheme(scheme: string, agentOption?: AgentOption): Agent | boolean | undefined
-
Parameters
Returns Agent
|
boolean
|
undefined
awaitAndReduce
- awaitAndReduce<T, U>(iterable: AsyncIterable<T>, callbackfn: function, initialValue: U): Promise<U>
-
Type parameters
Parameters
-
-
callbackfn: function
-
- (previousValue: U, currentValue: T): U
-
Parameters
-
previousValue: U
-
currentValue: T
Returns U
-
initialValue: U
Returns Promise<U>
delay
- delay<T>(ms: number, value?: T): Promise<T>
-
Type parameters
Parameters
-
ms: number
-
Optional value: T
Returns Promise<T>
getUserAgent
-
Returns string
The following is a polyfill of Node >= 8.2.0's util.callbackify method. The source is copied (with some modification) from: https://github.com/nodejs/node/blob/bff5d5b8f0c462880ef63a396d8912d5188bbd31/lib/util.js#L1095-L1140 The modified parts are denoted using comments starting with
original
and ending withmodified
This could really be made an independent module. It was suggested here: https://github.com/js-n/callbackify/issues/5