Though HGETALL and HINCRBY are implemented in Cluster class but in the types node module package its not defined. I had to do a hack to fix it by extending and just declaring the methods. Please fix it. The hack I did was:
interface MyCluster extends Cluster {
hgetall(key: IORedis.KeyType): Promise<Record<string, string>>;
hincrby(key: IORedis.KeyType, field: string, increment: number): Promise<number>;
}
I've opened a PR to add these and many other missing command definitions. The PR changes Cluster such that it inherits commands from a common Commands interface, which should hopefully make these definition gaps a thing of the past.
Should be fixed now with @types/ioredis 4.16.0
Most helpful comment
I've opened a PR to add these and many other missing command definitions. The PR changes
Clustersuch that it inherits commands from a commonCommandsinterface, which should hopefully make these definition gaps a thing of the past.