Vigikaran
Vigikaran

Reputation: 725

Is it possible to add custom commands to the Redis client for NodeJS?

I'm using the redis Node package for connecting, storing and retrieving data from Redis. Is it possible to add new commands to the client as Redis introduces those commands? For example, is there a way to define the GEOADD command on the client?

Upvotes: 1

Views: 1788

Answers (2)

Filipe Oliveira
Filipe Oliveira

Reputation: 1

as of version 2.8 of node-redis, it is possible to add arbitrary commands to the prototype by using Redis.addCommand(name)

Upvotes: 0

gnerkus
gnerkus

Reputation: 12047

It is not possible to add custom commands to the node-redis client. However, the ioredis package offers support for the new Redis commands.

Upvotes: 1

Related Questions